Skip to main content
GET
/
api
/
v1
/
garments
List Garments
curl --request GET \
  --url https://api.example.com/api/v1/garments
{
  "garments": [
    {
      "id": "<string>",
      "name": "<string>",
      "brand": "<string>",
      "category": "<string>",
      "basePrice": 123,
      "currency": "<string>",
      "colors": [
        {}
      ],
      "sizes": [
        {}
      ],
      "printZones": [
        {}
      ],
      "images": {}
    }
  ],
  "pagination": {
    "hasMore": true,
    "nextCursor": "<string>"
  }
}

List Garments

Retrieve available garment blanks with colors, sizes, and print zone information.
This endpoint is free — no tokens required.

Endpoint

GET https://garmint.app/api/v1/garments

Query Parameters

category
string
Filter by category: t-shirts, hoodies, tanks, long-sleeves, etc.
limit
number
default:"50"
Number of results to return (max 100).
cursor
string
Pagination cursor from previous response.

Response

garments
array
Array of garment objects.
pagination
object

Example

curl https://garmint.app/api/v1/garments?category=t-shirts&limit=10 \
  -H "Authorization: Bearer gm_live_xxx"

Response Example

{
  "garments": [
    {
      "id": "gildan-5000",
      "name": "Gildan 5000 Heavy Cotton Tee",
      "brand": "Gildan",
      "category": "t-shirts",
      "basePrice": 12.99,
      "currency": "USD",
      "colors": [
        {
          "name": "Black",
          "hex": "#000000",
          "imageUrl": "https://cdn.shopify.com/.../black.png",
          "available": true
        },
        {
          "name": "White",
          "hex": "#FFFFFF",
          "imageUrl": "https://cdn.shopify.com/.../white.png",
          "available": true
        }
      ],
      "sizes": ["S", "M", "L", "XL", "2XL"],
      "printZones": [
        {
          "id": "front",
          "name": "Front",
          "maxWidth": 12,
          "maxHeight": 14,
          "position": { "x": 50, "y": 35 }
        },
        {
          "id": "back",
          "name": "Back",
          "maxWidth": 12,
          "maxHeight": 14,
          "position": { "x": 50, "y": 35 }
        }
      ],
      "images": {
        "thumbnail": "https://cdn.shopify.com/.../thumb.png",
        "full": "https://cdn.shopify.com/.../full.png"
      }
    }
  ],
  "pagination": {
    "hasMore": true,
    "nextCursor": "eyJsYXN0SWQiOiJnaWxkYW4tNTAwMCJ9"
  }
}

Pagination

To fetch all garments, loop through pages using the cursor:
async function getAllGarments() {
  const garments = [];
  let cursor: string | undefined;
  
  do {
    const url = new URL('https://garmint.app/api/v1/garments');
    url.searchParams.set('limit', '100');
    if (cursor) url.searchParams.set('cursor', cursor);
    
    const response = await fetch(url, {
      headers: { 'Authorization': `Bearer ${API_KEY}` },
    });
    
    const data = await response.json();
    garments.push(...data.garments);
    cursor = data.pagination.hasMore ? data.pagination.nextCursor : undefined;
  } while (cursor);
  
  return garments;
}

Get Single Garment

Fetch details for a specific garment:
GET https://garmint.app/api/v1/garments/:id
curl https://garmint.app/api/v1/garments/gildan-5000 \
  -H "Authorization: Bearer gm_live_xxx"