API ReferenceSuppliers

Suppliers API

List suppliers

GET /brand/suppliers
Authorization: Bearer <token>
X-Organization-Id: <org_id>

Returns:

{
  "data": [
    {
      "id": "01KS...",
      "factoryName": "Guangzhou Garment Co.",
      "country": "CN",
      "tier": 1,
      "state": "confirmed",
      "contactEmail": "[email protected]",
      "certificateCount": 3,
      "productCount": 8,
      "batchCount": 12
    }
  ]
}

Invite supplier

POST /brand/suppliers/invite
Authorization: Bearer <token>
X-Organization-Id: <org_id>
Content-Type: application/json
 
{
  "factoryName": "Guangzhou Garment Co.",
  "contactEmail": "[email protected]",
  "country": "CN",
  "tier": 1,
  "notes": "Main garment supplier"
}

Sends an email invitation to the factory. If they already have a Pasera account, they’re automatically linked. Otherwise, they receive a signup link.

Get supplier detail

GET /brand/suppliers/:id
Authorization: Bearer <token>
X-Organization-Id: <org_id>

Returns:

{
  "id": "01KS...",
  "factoryName": "Guangzhou Garment Co.",
  "country": "CN",
  "tier": 1,
  "state": "confirmed",
  "contactEmail": "[email protected]",
  "facilities": [...],
  "certificates": [...],
  "subSuppliers": [...],
  "products": [
    {
      "id": "01KS...",
      "name": "Organic Cotton Jersey 180gsm",
      "productType": "fabric",
      "materials": [
        { "materialType": "cotton_organic", "percentage": 100, "originCountry": "TR" }
      ]
    }
  ],
  "batches": [...]
}

The supplier detail includes their full catalog (products with materials), certificates, facilities, sub-suppliers, and all batches they’ve been involved in.