Batch update tokens
Endpoint: PUT https://4zapi.com/api/token/batch
Batch-update tokens. ids is an int array; only fields listed in update_fields are applied.
Parameters
New-Api-User(header, string, required): Current user ID; must match the authenticated identity
Request body (application/json)
ids(array<integer>, required): Token IDs to updateupdate_fields(array<string>, required): Field names to updateallow_ips(string): IP allowlistexpired_time(integer): Expiration time (Unix timestamp)group(string): User groupmj_custom_proxy(string): Midjourney custom proxymj_image_mode(string): Midjourney image modemodel_limits(string): Model limit configurationmodel_limits_enabled(boolean): Whether model limits are enabledremain_quota(integer): Remaining quotarouting_priority(string): Routing priorityunlimited_quota(boolean): Whether quota is unlimited
Request example
{
"expired_time": -1,
"group": "default",
"ids": [
1,
2
],
"update_fields": [
"group",
"expired_time"
]
}