1.0.1
  • 1.0.1
  • 1.0.0
    1.0.1
    • 1.0.1
    • 1.0.0
    • Get Started
    • API Reference
      • Create Task
        • Image To Video
        • Instruct Edit
        • Try-On (Apparel)
        • Try-On (Accessories)
        • Lifestyle Scene
        • Swap Fashion Model
        • Background Replacer
        • Segment Image By Prompt
        • Segment Image By Type
        • Background Remover
      • Upload Asset File
        POST
      • List Preset Materials
        GET
      • Check Task Status
        GET
      • Get Download Url
        GET
      • Retrieve API Credit Usage
        GET
    • Help
      • Download File Samples
      • Error Codes
      • FAQ

    Get Started

    For technical support or additional assistance, contact support@sellerpic.ai.


    Obtain Your API Key

    Apply for an API Key to authenticate your API requests.

    Include the API Key in the Authorization header of all API requests as shown below:


    API Request Example

    curl --location --request POST 'https://api.sellerpic.ai/v1/api/generate/instructEdit' \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
      "imageKey": "UPLOAD/1911986840705904640/2025/04/16/e562bc9273cb4edab3b7c0ea36787b7f.jpg",
      "prompt": "The model touches her hairband and her face slightly turns to the side."
    }'
    

    Note
    Replace YOUR_API_KEY with the API key obtained from your application.


    Task Concurrency Limits

    This API enforces hard concurrent task limits per account. Task creation requests will fail immediately when the number of in-progress tasks reaches these thresholds:

    Task typeMax Concurrent Tasks
    Image to Video10
    Instruct Edit5
    Segment image by prompt5
    Segment image by type5
    All Other task10

    Note

    1. Task Counting: Includes all tasks in CREATED RUNNING
    2. Rejection Behavior: Receive immediate error code 30003 response
    3. Capacity Release: Task slots become available when tasks reach to SUCCESS or FAILED

    Workflow Overview

    image.png


    1. Upload Asset Files

    • API Reference: Upload Asset File
    • Submit a single asset file per request via POST with the header:
      Content-Type: multipart/form-data
    • Response: fileKey Unique identifier for successfully uploaded asset.

    2. Create Generation Task

    Prerequisite

    • Complete the previous step (Upload Asset Files)
    • Obtain valid fileKey from upload response

    Create Task Endpoints:

    • Image To Video
    • Instruct Edit
    • Try-On (Apparel)
    • Try-On (Accessories)
    • Lifestyle Scene
    • Swap Fashion Model
    • Background Replacer
    • Segment Image By Prompt
    • Segment Image By Type
    • Background Remover

    Response Handling
    The response includes a id field. Use this unique identifier to track task progress via the next step: Check Task Status.


    3. Check Task Status

    • API Reference: Check Task Status API.
    • Polling Requirements
      • Minimum 60-second interval between requests
      • Monitor until task reaches terminal state SUCCESS or FAILED
    • Critical Dependency
      Successfully generated files are exclusively retrievable via the next step: Get Download URL.

    4. Get Download URL

    • API Reference: Get Download Url API
    • Returns a time-limited URL for accessing generated files.

    5. Download File

    • Execute a GET request using the download url from previous Step 4
    • Please complete the download within 12 hour (temporary URL Expiration)
    • If you receive a 403 Forbidden response (indicating URL expiration), Call the Get Download Url API API endpoint with your original task id to generate a new valid URL.

    Code Examples


    Credit Deduction Rules

    TaskCredits Rule
    Swap Fashion Model1 Credit/image(4 images at once)
    Try-on(Apparel)1 Credit/image(4 images at once)
    Try-on(Accessories)1 Credit/image(2 images at once)
    Image to Video(Standard,5s)10 Credit/video
    Image to Video(Standard,10s)15 Credit/video
    Lifestyle Scene1 Credit/image(4 images at once)
    Instruct Edit1 Credit/image
    Background Replacer1 Credit/image(4 images at once)
    Background Remover1 Credit/image

    Error Codes

    The error code list helps you quickly identify issues.

    CodeDescription
    0Success. The request was processed successfully.
    400Failed to validate the parameter.
    403Forbidden.
    404Empty data.
    500Server is busy, please try again later.
    504Request timeout, please try again later.
    5001Data not found.
    5002Unknown enums.
    5003Field validation failed.
    5004Download file failed.
    5005Too many attempts.
    10015API authentication failed. Please check authorization header.
    20000Service unavailable. The requested service is temporarily unavailable.
    20001Authorization failed. Insufficient permissions or invalid access tokens.
    20002Invalid user token. The user authorization token is invalid.
    20014Insufficient credits remaining to use.
    30001Image make timeout.
    30002Image make failed.
    30003Task limit reached. Please wait for completion.
    30004Image param error. Image cannot be fully transparent.
    30005Image param error. Image must have transparent area.
    30006Image make failed.
    30007No setting image operate.
    30008Download file failed.
    30009Image make sensitive content.
    30010Image make version not support.
    30011Free task too much. Please upgrade your account.
    30012Task limit reached. Please wait for completion.
    30013Image not found.
    30014Unable to process the image. Please try a different image.
    30015Animated WEBP file is not supported.
    30016The file size exceeds the limit.
    30017Image not finished.
    30018Image make type not support.
    30019Download format not support.
    30020Image is broken.
    30021Image format error.
    30022Upload file fail.
    30023Model image unrecognized.
    30024Image illegal.
    30025Background color invalid.
    30026File not found.
    30027Image too large.
    40000Missing user token. The required user access token is missing.
    40001Missing required parameters. A mandatory parameter is missing in the request.
    40002Invalid parameters. The provided parameters are invalid or malformed.
    40004Business processing failed. The request could not be processed due to business logic issues.
    40005Unknown error. An unexpected error occurred; contact support.
    40006Insufficient permissions. The requester lacks the necessary permissions.
    40007Missing app token. The required application authorization token is missing.
    42900Server busy. The server is overloaded; try again later.
    50001Unauthorized API. The requested API is not authorized for the user.
    Modified at 2025-07-22 12:44:33
    Next
    Image To Video
    Built with