Create sign-in background upload session. POST /api/openapi/v1/personalization/login-background-upload-sessions, scope admin.v1.personalization.manage.
- Scope:
admin.v1.personalization.manage - Permission: Manage Personalization
- Action: manage
- Endpoint: POST
/api/openapi/v1/personalization/login-background-upload-sessions
Authorization: Bearer \<API_KEY\>. The application must have subject_scope={"mode":"all"}; restricted scopes return 403. Scopes are independently granted. Do not cache responses.
Reuses the UI personalization service. Publication replaces the entire section and requires its current expected_revision; stale revisions return 409. Read and preserve other homepage fields when changing welcome messages.
For a sign-in background, create a session with media_type and size_bytes, upload directly using the returned URL, method and headers, then publish login config.backgroundUploadId referencing upload_id.
PNG/JPEG only, at most 5 MiB and at least 720×720. Sessions are bound to the organization and uploader and require Idempotency-Key. Only login, homepage and input-placeholder are exposed.
Common request headers
Apply the “Authentication and headers” section in “Configure the QwenWork console through APIs”: Authorization is required and X-Request-Id is optional. See this page for the required scope.
Whether Idempotency-Key applies and is required is specified in this page’s request parameters; a tracing identifier does not replace an idempotency key.
Request parameters
Request body: required; Content-Type: application/json.
| Name | Location | Type | Required | Description | Example |
|---|---|---|---|---|---|
Idempotency-Key | header | string | Yes | Idempotency-Key; maxLength=255 | - |
media_type | body | string | Yes | media type; enum=["image/png", "image/jpeg"] Values: "image/jpeg", "image/png" | - |
size_bytes | body | integer · int64 | Yes | size bytes; format="int64", minimum=1, maximum=5242880 | - |
Response statuses
| HTTP status | Trigger | Response structure | Client action |
|---|---|---|---|
201 | Request succeeded | See “Response” on this page | Read the response. |
default | Other authentication, authorization, validation or dependency errors | See “General error” in “Configure the QwenWork console through APIs” | Handle the status and code; verify the result and idempotency requirements before retrying writes. |
Response
Content-Type: application/json
| Name | Type | Required | Description | Example |
|---|---|---|---|---|
max_size_bytes | integer · int64 | Yes | max size bytes; format="int64" | - |
upload_headers | object | Yes | upload headers | - |
upload_id | string | Yes | upload id | - |
upload_method | string | Yes | upload method | - |
upload_url | string · uri | Yes | upload url; format="uri" | - |
upload_url_expires_at | string · date-time | Yes | upload url expires at; format="date-time" | - |