Skip to content

First product ​

Upload your first product with a seller key in five steps. In the examples $KEY is your key.

StepEndpoint
1. Check the accountGET /seller
2. Pick a categoryGET /seller/categories
3. Send the productPOST /seller/products
4. Wait for the resultGET /seller/jobs/{id}
5. See the productGET /seller/products/{id}

1. Check the account ​

sh
curl https://api.ustageliyor.com/v1/seller -H "Authorization: Bearer $KEY"

Returns seller.status and seller.listable. A 403 SELLERS_DISABLED means external sellers are not open yet; see the overview.

2. Pick a category ​

sh
curl https://api.ustageliyor.com/v1/seller/categories \
  -H "Authorization: Bearer $KEY"
json
{
  "categories": [
    {
      "id": "pcat_…",
      "name": "El Aletleri",
      "handle": "el-aletleri",
      "attributes": [
        {
          "name": "Güç Kaynağı",
          "required": true,
          "values": ["Akülü", "Kablolu"]
        }
      ]
    }
  ]
}

Attributes with required: true are needed to publish; when values is set only those values are accepted. A draft product saves without them.

3. Send the product ​

Products always go through the bulk endpoint; one product is a list of one.

sh
curl -X POST https://api.ustageliyor.com/v1/seller/products \
  -H "Authorization: Bearer $KEY" -H "Content-Type: application/json" \
  -H "Idempotency-Key: first-product-2026-10-23" \
  -d '{
    "products": [{
      "title": "Akülü Vidalama 12V",
      "brand": "Usta İş",
      "category_id": "pcat_…",
      "status": "published",
      "deliveries": ["cargo"],
      "tax_rate": 20,
      "desi": 3,
      "images": ["https://cdn.example.com/vda-12.jpg"],
      "attributes": [{ "name": "Güç Kaynağı", "value": "Akülü" }],
      "variants": [{
        "sku": "VDA-12",
        "barcode": "8680000000059",
        "price": 1299.90,
        "list_price": 1499.90,
        "stock": 8
      }]
    }]
  }'

The answer is a 202 with a job:

json
{
  "job": {
    "id": "mij_…",
    "source": "api",
    "status": "queued",
    "total": 1,
    "processed": 0
  }
}

4. Wait for the result ​

sh
curl https://api.ustageliyor.com/v1/seller/jobs/mij_… \
  -H "Authorization: Bearer $KEY"

Poll every few seconds until status is done. results holds the per-product outcome:

json
{
  "job": {
    "id": "mij_…",
    "status": "done",
    "total": 1,
    "processed": 1,
    "created": 1,
    "updated": 0,
    "failed": 0,
    "results": [
      {
        "index": 0,
        "ref": "VDA-12",
        "ok": true,
        "product_id": "prod_…",
        "created": true
      }
    ]
  }
}

A failed product carries ok: false, a code (e.g. MARKET_PRODUCT_INVALID) and the bad fields (problems, e.g. ["variants.0.price"]).

5. See the product ​

sh
curl https://api.ustageliyor.com/v1/seller/products/prod_… \
  -H "Authorization: Bearer $KEY"

The product comes with its variants and their stock (on the shelf) and available (sellable) counts. Sending the same product again — same model_code or same stock codes — opens no new product; the existing one is updated.

Next: Product model.