### Getting Started with the API Source: https://dev.wildberries.ru/docs/openapi/api-information/index A step-by-step guide on how to get started with the WB API, including registration, creating an API token, and developing integrations. It also offers practical tips for effective API usage. ```APIDOC ## Getting Started with the API ### Description Guides users through the process of getting started with the WB API, from registration to integration development, with practical usage tips. ### Steps 1. Register in the seller personal account. 2. Go to store settings and create an API token. 3. Develop an integration with the API. ### Practical Tips - Use the official documentation. - Regularly check the integration. - Keep the API token secure. - Contact technical support if needed. - Stay updated on WB API news. ``` -------------------------------- ### General API Information Source: https://dev.wildberries.ru/docs/openapi/api-information/index This section provides general information about the WB API, including how to get started, log in, create tokens, understand HTTP status codes, manage rate limits, and contact support. ```APIDOC ## General API Information ### Description Provides general information about the WB API, including getting started, authentication, status codes, rate limits, and support. ### Methods Available - Check WB API connection - Get seller portal news - Get seller information - Manage seller users ``` -------------------------------- ### WB API Authorization Header Example Source: https://dev.wildberries.ru/docs/openapi/api-information/index This example shows how to include the API token in the `Authorization` header for authenticating requests to the WB API. The token is obtained separately and is valid for 180 days. ```http GET /some/api/endpoint HTTP/1.1 Host: api.wb.ru Authorization: Bearer YOUR_API_TOKEN ``` -------------------------------- ### User Accesses Payload Example (JSON) Source: https://dev.wildberries.ru/docs/openapi/api-information/index This JSON payload demonstrates the structure for specifying user accesses, including user IDs and their associated permissions (e.g., 'balance', 'finance', 'feedbacks'). It shows how to enable or disable specific access codes for each user. ```json { "usersAccesses": [ { "userId": 42334965, "access": [ { "code": "balance", "disabled": false }, { "code": "finance", "disabled": true }, { "code": "feedbacks", "disabled": false } ] }, { "userId": 52334965, "access": [ { "code": "balance", "disabled": true }, { "code": "changeJam", "disabled": false }, { "code": "showcase", "disabled": false } ] } ] } ``` -------------------------------- ### Getting Seller Portal News /api/communications/v2/news Source: https://dev.wildberries.ru/docs/openapi/api-information/index Retrieves news from the seller portal. Requires either the 'from' or 'fromID' parameter to be specified. Allows fetching up to 100 news items per request. ```APIDOC ## GET /api/communications/v2/news ### Description Retrieves news from the seller portal. To receive a successful response, one of the parameters `from` or `fromID` must be specified. You can get up to 100 news items per request. Request limit per one seller's account: 1 request per minute. ### Method GET ### Endpoint `https://common-api.wildberries.ru/api/communications/v2/news` ### Parameters #### Query Parameters - **from** (string) - Optional - Date from which to get news (e.g., `from=2025-02-06`). - **fromID** (integer) - Optional - The news ID, starting from which (including it) you need to get the list of news (e.g., `fromID=7369`). ### Request Example ``` GET https://common-api.wildberries.ru/api/communications/v2/news?from=2025-02-06 ``` ### Response #### Success Response (200) - The response will contain a list of news items matching the query criteria. #### Response Example (Example response structure would be provided here if available in the source text) #### Error Responses - **400**: Bad request - **401**: Unauthorized - **429**: Too many requests ``` -------------------------------- ### Delete User API Endpoint (Example) Source: https://dev.wildberries.ru/docs/openapi/api-information/index This snippet describes the DELETE request to the /api/v1/user endpoint for managing user access on the Wildberries platform. It outlines the method, URL, purpose, request limits, authorization, query parameters, and possible responses. ```text DELETE https://user-management-api.wildberries.ru/api/v1/user Method description: The method removes a user from the seller user list. This user will no longer have access to the seller account. Request limit per one seller's account: 1 request per 1 s (Burst: 10 requests) Authorizations: HeaderApiKey Query Parameters: deletedUserID (required, integer ): ID of the user whose access will be revoked. Responses: 200: Success 400: Bad request 401: Unauthorized 429: Too many requests ``` -------------------------------- ### API Introduction Source: https://dev.wildberries.ru/docs/openapi/api-information/index An introduction to the Wildberries API, highlighting its benefits for sellers such as automation, real-time data access, and inventory optimization. It also mentions the API documentation format (Swagger OpenAPI) and tools for testing. ```APIDOC ## API Introduction ### Description Introduces the Wildberries API, its advantages for sellers (automation, data access, inventory optimization), and the documentation format (Swagger OpenAPI). ### Key Benefits - Automate routine processes - Access up-to-date information - Optimize inventory management ### Testing Tools - PostMan (Windows) - curl (Linux) ``` -------------------------------- ### Wildberries API User Access Response Sample (JSON) Source: https://dev.wildberries.ru/docs/openapi/api-information/index This JSON snippet represents a successful response from the Wildberries API, detailing user information and their access permissions. It includes total user count, response count, and a list of users with their roles, contact information, and specific access rights. ```json { "total": 2, "countInResponse": 2, "users": [ { "id": 0, "role": "", "position": "Аналитик", "phone": "79998888888", "email": "", "isOwner": false, "firstName": "", "secondName": "", "patronymic": "", "goodsReturn": false, "isInvitee": true, "inviteeInfo": { "phoneNumber": "79998888888", "position": "Аналитик", "inviteUuid": "00000000-0000-4000-8000-000000000001", "expiredAt": "2025-12-01T00:00:00Z", "isActive": true }, "access": [ { "code": "supply", "disabled": true }, { "code": "changeJam", "disabled": true }, { "code": "showcase", "disabled": false }, { "code": "suppliersDocuments", "disabled": false }, { "code": "discountPrice", "disabled": true }, { "code": "feedbacks", "disabled": false }, { "code": "questions", "disabled": false }, { "code": "wbPoint", "disabled": false }, { "code": "brands", "disabled": true }, { "code": "pointsForReviews", "disabled": false }, { "code": "pinFeedbacks", "disabled": false }, { "code": "finance", "disabled": true }, { "code": "feedbacksQuestions", "disabled": false }, { "code": "balance", "disabled": false } ] }, { "id": 0, "role": "", "position": "", "phone": "7999XXXX102", "email": "", "isOwner": false, "firstName": "", "secondName": "", "patronymic": "", "goodsReturn": false, "isInvitee": true, "inviteeInfo": { "phoneNumber": "79996666666", "position": "Аналитик", "inviteUuid": "00000000-0000-4000-8000-000000000002", "expiredAt": "2025-12-10T00:00:00Z", "isActive": false }, "access": [ { "code": "supply", "disabled": true }, { "code": "changeJam", "disabled": true }, { "code": "showcase", "disabled": false }, { "code": "suppliersDocuments", "disabled": false }, { "code": "discountPrice", "disabled": true }, { "code": "feedbacks", "disabled": false }, { "code": "questions", "disabled": false }, { "code": "wbPoint", "disabled": false }, { "code": "brands", "disabled": true }, { "code": "pointsForReviews", "disabled": false }, { "code": "pinFeedbacks", "disabled": false }, { "code": "finance", "disabled": true }, { "code": "feedbacksQuestions", "disabled": false }, { "code": "balance", "disabled": false } ] } ] } ``` -------------------------------- ### Handling 429 Rate Limit Error in WB API Source: https://dev.wildberries.ru/docs/openapi/api-information/index This snippet demonstrates how to interpret and act upon a 429 Too Many Requests error response from the WB API. It focuses on using the `X-Ratelimit-Retry` and `X-Ratelimit-Reset` headers to determine when to resend a request and when the request burst limit will be replenished. ```http HTTP/1.1 429 Too Many Requests ... X-Ratelimit-Reset: 29 ... X-Ratelimit-Retry: 2 ... X-Ratelimit-Limit: 10 ``` -------------------------------- ### HTTP Status Codes Source: https://dev.wildberries.ru/docs/openapi/api-information/index Details the main HTTP status codes returned by the WB API, their descriptions, and how to resolve associated issues. ```APIDOC ## HTTP Status Codes ### Description Lists and explains common HTTP status codes returned by the WB API, along with guidance on how to resolve errors. ### Status Codes - **200** - Success - **204** - Deleted/Updated/Confirmed - **400** - Bad request (Check request syntax) - **401** - Unauthorized (Check authorization token: expired, incorrect, or missing) - **403** - Access denied (Token generated by deleted user, access blocked, or missing subscription for Jam methods) - **404** - Not found (Check request URL) - **409** - Status update error/Error adding label/etc (Check request data against service requirements) - **413** - Request body size exceeds limit (Reduce the number of objects in the request) - **422** - Error processing request parameters/Unexpected result/etc (Check request data for contradictions) - **429** - Too many requests (Check method rate limits and retry later) - **5XX** - Internal service error (Service unavailable, retry later or contact support) ### Error Details Pay attention to the `details` field in `404` and `429` errors for useful information. ``` -------------------------------- ### Connection Check /ping Source: https://dev.wildberries.ru/docs/openapi/api-information/index Checks the connection to the Wildberries API, validates authorization tokens, and ensures the token category matches the service. Note that this is a general ping and specific services may have their own ping endpoints. ```APIDOC ## GET /ping ### Description Checks the connection to the Wildberries API, validates authorization tokens, and ensures the token category matches the service. This method is not intended to check the availability of WB services. Each service has its own version of the method depending on the domain. A maximum of 3 requests every 30 seconds is allowed. The rate limit applies individually to each instance of the method on each host. ### Method GET ### Endpoint `https://common-api.wildberries.ru/ping` ### Parameters This endpoint does not have any path, query, or request body parameters. ### Request Example This endpoint does not require a request body. ### Response #### Success Response (200) - **TS** (string) - Timestamp of the response. - **Status** (string) - Status of the connection check, typically 'OK'. #### Response Example ```json { "TS": "2024-08-16T11:19:05+03:00", "Status": "OK" } ``` #### Error Responses - **401**: Unauthorized - **429**: Too many requests ``` -------------------------------- ### Bad Request Response Sample (JSON) Source: https://dev.wildberries.ru/docs/openapi/api-information/index This JSON object represents a 'Bad Request' (400) response from the Wildberries API. It typically indicates an issue with the request, such as a user not being associated with the current supplier account. The response includes a status, title, detail message, request ID, and origin. ```json { "title": "Bad Request", "status": 400, "detail": "bad request cause: user is not in current supplier", "requestId": "c479c04d0b576a9ba0b20fdf235004c2", "origin": "public-acl" } ``` -------------------------------- ### Update User Access Permissions API Request (JSON) Source: https://dev.wildberries.ru/docs/openapi/api-information/index This JSON structure defines the request body for updating user access permissions via the Wildberries API. It requires an array of user access objects, where each object specifies the user and their desired access settings. This method allows for partial updates to user permissions. ```json { "usersAccesses": [ { "userId": 123, "access": [ { "code": "supply", "disabled": false }, { "code": "showcase", "disabled": true } ] }, { "userId": 456, "access": [ { "code": "feedbacks", "disabled": false } ] } ] } ``` -------------------------------- ### Update User Access Permissions Source: https://dev.wildberries.ru/docs/openapi/api-information/index This endpoint allows you to update the access rights for one or more users. Only the fields provided in the request body will be modified; other fields will remain unchanged. Rate limits apply per seller account. ```APIDOC ## PUT /api/v1/users/access ### Description Updates the access rights for one or more users. Only the data passed in the request parameters will be updated. The other fields will remain unchanged. **Request limit per one seller's account:** - **Period:** 1 s - **Limit:** 1 request - **Interval:** 1 s - **Burst:** 5 requests ### Method PUT ### Endpoint https://user-management-api.wildberries.ru/api/v1/users/access ### Parameters #### Request Body - **usersAccesses** (array[UserAccess]) - Required - An array of objects, where each object contains the access settings for a user. ##### UserAccess Object - **id** (integer) - Required - The unique identifier for the user. - **access** (array[AccessItem]) - Required - A list of access permissions for the user. ###### AccessItem Object - **code** (string) - Required - The code representing the access permission (e.g., "supply", "feedbacks"). - **disabled** (boolean) - Required - Indicates whether the access is disabled (true) or enabled (false). ### Request Example ```json { "usersAccesses": [ { "id": 123, "access": [ { "code": "supply", "disabled": false }, { "code": "feedbacks", "disabled": true } ] } ] } ``` ### Response #### Success Response (200) - **message** (string) - A success message indicating the update was successful. #### Response Example (200) ```json { "message": "Access rights updated successfully" } ``` #### Error Responses - **400** Bad request - **401** Unauthorized - **429** Too many requests ``` -------------------------------- ### Delete User /api/v1/user Source: https://dev.wildberries.ru/docs/openapi/api-information/index The method removes a user from the seller user list. This user will no longer have access to the seller account. ```APIDOC ## DELETE /api/v1/user ### Description The method removes a user from the seller user list. This user will no longer have access to the seller account. ### Method DELETE ### Endpoint https://user-management-api.wildberries.ru/api/v1/user ### Parameters #### Query Parameters - **deletedUserID** (integer) - Required - ID of the user whose access will be revoked ### Responses #### Success Response (200) Success #### Error Response (400) Bad request #### Error Response (401) Unauthorized #### Error Response (429) Too many requests #### Response Example (400) ```json { "title": "Bad Request", "status": 400, "detail": "bad request cause: user is not in current supplier", "requestId": "c479c04d0b576a9ba0b20fdf235004c2", "origin": "public-acl" } ``` ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.