Upload token JSON files, refresh them, and download the updated result.
- JDK 17+
- Maven 3.6+
mvn spring-boot:runOr build and run the jar:
mvn clean package -DskipTests
java -jar target/token-refresh-1.0.0.jarPOST http://localhost:8080/token/refresh
Parameter: file (multipart/form-data)
Supported uploads:
- A single
.jsontoken file. The response is the refreshed JSON file. - A
.ziparchive containing one or more.jsontoken files. The response is a new ZIP containing the refreshed JSON files. Directories and non-JSON files are skipped.
Refresh one JSON file:
curl -X POST http://localhost:8080/token/refresh \
-F "file=@token.json" \
-o token_new.jsonRefresh JSON files inside a ZIP archive:
curl -X POST http://localhost:8080/token/refresh \
-F "file=@tokens.zip" \
-o refreshed_tokens.zipclient_idis parsed automatically from theaudfield in theid_tokenpayload.- JSON output file names use the format
APLUS-{email}.json. - ZIP output file names use the format
refreshed_tokens_yyyyMMdd_HHmmss.zip. refresh_tokenandid_tokenare updated when the refresh API returns rotated values.