Docs
Dashboard
On this page

    Product presets

    6 endpoints. Each needs an API key or OAuth token with the scope shown; the key already names its store, so paths start at /v1/store. Generated from the live contract; also in openapi.json.

    ShopFast's product presets (with this store's edits) and the store's own presets

    GET/v1/store/product-presets

    Or name the store: GET /v1/stores/{storeId}/product-presets

    catalog:readrole: catalog:readlistProductPresets

    Response ListProductPresetsResponse

    • presetsProductPreset[]required

    Example

    curl "https://api.shopfa.st/v1/store/product-presets" \
      -H "Authorization: Bearer $SHOPFAST_API_KEY"
    const res = await fetch('https://api.shopfa.st/v1/store/product-presets', {
      method: 'GET',
      headers: {
        Authorization: `Bearer ${process.env.SHOPFAST_API_KEY}`,
      },
    });
    if (!res.ok) throw new Error((await res.json()).detail);
    const data = await res.json();
    import os, requests
    
    res = requests.request(
        "GET",
        "https://api.shopfa.st/v1/store/product-presets",
        headers={"Authorization": f"Bearer {os.environ['SHOPFAST_API_KEY']}"},
    )
    res.raise_for_status()
    data = res.json()
    req, _ := http.NewRequest("GET", "https://api.shopfa.st/v1/store/product-presets", nil)
    req.Header.Set("Authorization", "Bearer "+os.Getenv("SHOPFAST_API_KEY"))
    res, err := http.DefaultClient.Do(req)
    Try it with your key

    Use a test key on a development store. The key stays in this tab (sessionStorage) and is sent only to the base URL above.

    Save a preset of your own

    POST/v1/store/product-presets

    Or name the store: POST /v1/stores/{storeId}/product-presets

    catalog:writerole: catalog:writecreateProductPreset

    Body

    • namestringrequired
    • descriptionstringrequired
    • icon"key" | "shield" | "user" | "code" | "discord" | "download" | "calendar" | "box" | "bolt" | "star"required
    • type"file" | "license_key" | "serial" | "subscription" | "discord_role" | "service" | "bundle"required
    • titleTemplatestringrequired
    • shortDescriptionstringrequired
    • descriptionMdstringrequired
    • tagsstring[]required
    • optionsobject[]required
      • namestringrequired
      • priceMinorintegerrequired
      • compareAtMinorinteger | null
      • descriptionstring
      • deliveryNotestring
    • priceMinorintegerrequired
    • platforms"windows" | "mac" | "linux" | "steam" | "epic" | "battlenet" | "riot" | "ea" | "ubisoft" | "xbox" | "playstation" | "switch" | "android" | "ios" | "web" | "other"[]required
    • regionstring | nullrequired
    • status"undetected" | "updated" | "testing" | "updating" | "detected" | "down" | nullrequired
    • instantDeliverybooleanrequired
    • keyInstructionsstringrequired
    • postPurchaseMessagestringrequired
    • maxPerOrderinteger | nullrequired
    • needsGamebooleanrequired
    • downloadLimitinteger | nullrequired
    • stockinteger | nullrequired
    • turnaroundDaysinteger | nullrequired
    • discordRoleNamestringrequired

    Response ProductPreset

    • namestringrequired
    • descriptionstringrequired
    • iconPresetIconrequired
    • typeProductTyperequired
    • titleTemplatestringrequired
    • shortDescriptionstringrequired
    • descriptionMdstringrequired
    • tagsstring[]required
    • optionsPresetOption[]required
    • priceMinorMinorUnitsrequired
    18 more fields
    • platformsGamePlatform[]required
    • regionstring | nullrequired
    • statusProductLiveStatus | nullrequired
    • instantDeliverybooleanrequired
    • keyInstructionsstringrequired
    • postPurchaseMessagestringrequired
    • maxPerOrderinteger | nullrequired
    • needsGamebooleanrequired
    • downloadLimitinteger | nullrequired
    • stockinteger | nullrequired
    • turnaroundDaysinteger | nullrequired
    • discordRoleNamestringrequired
    • keyPresetKeyrequired
    • builtinbooleanrequired
    • editedbooleanrequired
    • isDefaultbooleanrequired
    • productCountintegerrequired
    • updatedAtTimestamp | nullrequired

    Example

    curl -X POST "https://api.shopfa.st/v1/store/product-presets" \
      -H "Authorization: Bearer $SHOPFAST_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
      "name": "string",
      "description": "string",
      "icon": "key",
      "type": "file",
      "titleTemplate": "string",
      "shortDescription": "string",
      "descriptionMd": "string",
      "tags": [
        "string"
      ],
      "options": [
        {
          "name": "string",
          "priceMinor": 0
        }
      ],
      "priceMinor": 0,
      "platforms": [
        "windows"
      ],
      "region": "string",
      "status": "undetected",
      "instantDelivery": false,
      "keyInstructions": "string",
      "postPurchaseMessage": "string",
      "maxPerOrder": 1,
      "needsGame": false,
      "downloadLimit": 1,
      "stock": 0,
      "turnaroundDays": 1,
      "discordRoleName": "string"
    }'
    const res = await fetch('https://api.shopfa.st/v1/store/product-presets', {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.SHOPFAST_API_KEY}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "name": "string",
        "description": "string",
        "icon": "key",
        "type": "file",
        "titleTemplate": "string",
        "shortDescription": "string",
        "descriptionMd": "string",
        "tags": [
          "string"
        ],
        "options": [
          {
            "name": "string",
            "priceMinor": 0
          }
        ],
        "priceMinor": 0,
        "platforms": [
          "windows"
        ],
        "region": "string",
        "status": "undetected",
        "instantDelivery": false,
        "keyInstructions": "string",
        "postPurchaseMessage": "string",
        "maxPerOrder": 1,
        "needsGame": false,
        "downloadLimit": 1,
        "stock": 0,
        "turnaroundDays": 1,
        "discordRoleName": "string"
      }),
    });
    if (!res.ok) throw new Error((await res.json()).detail);
    const data = await res.json();
    import os, requests
    
    res = requests.request(
        "POST",
        "https://api.shopfa.st/v1/store/product-presets",
        headers={"Authorization": f"Bearer {os.environ['SHOPFAST_API_KEY']}"},
        json={
          "name": "string",
          "description": "string",
          "icon": "key",
          "type": "file",
          "titleTemplate": "string",
          "shortDescription": "string",
          "descriptionMd": "string",
          "tags": [
            "string"
          ],
          "options": [
            {
              "name": "string",
              "priceMinor": 0
            }
          ],
          "priceMinor": 0,
          "platforms": [
            "windows"
          ],
          "region": "string",
          "status": "undetected",
          "instantDelivery": False,
          "keyInstructions": "string",
          "postPurchaseMessage": "string",
          "maxPerOrder": 1,
          "needsGame": False,
          "downloadLimit": 1,
          "stock": 0,
          "turnaroundDays": 1,
          "discordRoleName": "string"
        },
    )
    res.raise_for_status()
    data = res.json()
    req, _ := http.NewRequest("POST", "https://api.shopfa.st/v1/store/product-presets", strings.NewReader(`{
      "name": "string",
      "description": "string",
      "icon": "key",
      "type": "file",
      "titleTemplate": "string",
      "shortDescription": "string",
      "descriptionMd": "string",
      "tags": [
        "string"
      ],
      "options": [
        {
          "name": "string",
          "priceMinor": 0
        }
      ],
      "priceMinor": 0,
      "platforms": [
        "windows"
      ],
      "region": "string",
      "status": "undetected",
      "instantDelivery": false,
      "keyInstructions": "string",
      "postPurchaseMessage": "string",
      "maxPerOrder": 1,
      "needsGame": false,
      "downloadLimit": 1,
      "stock": 0,
      "turnaroundDays": 1,
      "discordRoleName": "string"
    }`))
    req.Header.Set("Authorization", "Bearer "+os.Getenv("SHOPFAST_API_KEY"))
    req.Header.Set("Content-Type", "application/json")
    res, err := http.DefaultClient.Do(req)
    Try it with your key

    Use a test key on a development store. The key stays in this tab (sessionStorage) and is sent only to the base URL above.

    Edit a preset (a built-in one becomes your store's copy)

    PUT/v1/store/product-presets/{presetKey}

    Or name the store: PUT /v1/stores/{storeId}/product-presets/{presetKey}

    catalog:writerole: catalog:writesaveProductPreset

    Parameters

    • presetKeystringpathrequired

    Body

    • namestringrequired
    • descriptionstringrequired
    • icon"key" | "shield" | "user" | "code" | "discord" | "download" | "calendar" | "box" | "bolt" | "star"required
    • type"file" | "license_key" | "serial" | "subscription" | "discord_role" | "service" | "bundle"required
    • titleTemplatestringrequired
    • shortDescriptionstringrequired
    • descriptionMdstringrequired
    • tagsstring[]required
    • optionsobject[]required
      • namestringrequired
      • priceMinorintegerrequired
      • compareAtMinorinteger | null
      • descriptionstring
      • deliveryNotestring
    • priceMinorintegerrequired
    • platforms"windows" | "mac" | "linux" | "steam" | "epic" | "battlenet" | "riot" | "ea" | "ubisoft" | "xbox" | "playstation" | "switch" | "android" | "ios" | "web" | "other"[]required
    • regionstring | nullrequired
    • status"undetected" | "updated" | "testing" | "updating" | "detected" | "down" | nullrequired
    • instantDeliverybooleanrequired
    • keyInstructionsstringrequired
    • postPurchaseMessagestringrequired
    • maxPerOrderinteger | nullrequired
    • needsGamebooleanrequired
    • downloadLimitinteger | nullrequired
    • stockinteger | nullrequired
    • turnaroundDaysinteger | nullrequired
    • discordRoleNamestringrequired

    Response ProductPreset

    • namestringrequired
    • descriptionstringrequired
    • iconPresetIconrequired
    • typeProductTyperequired
    • titleTemplatestringrequired
    • shortDescriptionstringrequired
    • descriptionMdstringrequired
    • tagsstring[]required
    • optionsPresetOption[]required
    • priceMinorMinorUnitsrequired
    18 more fields
    • platformsGamePlatform[]required
    • regionstring | nullrequired
    • statusProductLiveStatus | nullrequired
    • instantDeliverybooleanrequired
    • keyInstructionsstringrequired
    • postPurchaseMessagestringrequired
    • maxPerOrderinteger | nullrequired
    • needsGamebooleanrequired
    • downloadLimitinteger | nullrequired
    • stockinteger | nullrequired
    • turnaroundDaysinteger | nullrequired
    • discordRoleNamestringrequired
    • keyPresetKeyrequired
    • builtinbooleanrequired
    • editedbooleanrequired
    • isDefaultbooleanrequired
    • productCountintegerrequired
    • updatedAtTimestamp | nullrequired

    Example

    curl -X PUT "https://api.shopfa.st/v1/store/product-presets/string" \
      -H "Authorization: Bearer $SHOPFAST_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
      "name": "string",
      "description": "string",
      "icon": "key",
      "type": "file",
      "titleTemplate": "string",
      "shortDescription": "string",
      "descriptionMd": "string",
      "tags": [
        "string"
      ],
      "options": [
        {
          "name": "string",
          "priceMinor": 0
        }
      ],
      "priceMinor": 0,
      "platforms": [
        "windows"
      ],
      "region": "string",
      "status": "undetected",
      "instantDelivery": false,
      "keyInstructions": "string",
      "postPurchaseMessage": "string",
      "maxPerOrder": 1,
      "needsGame": false,
      "downloadLimit": 1,
      "stock": 0,
      "turnaroundDays": 1,
      "discordRoleName": "string"
    }'
    const res = await fetch('https://api.shopfa.st/v1/store/product-presets/string', {
      method: 'PUT',
      headers: {
        Authorization: `Bearer ${process.env.SHOPFAST_API_KEY}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "name": "string",
        "description": "string",
        "icon": "key",
        "type": "file",
        "titleTemplate": "string",
        "shortDescription": "string",
        "descriptionMd": "string",
        "tags": [
          "string"
        ],
        "options": [
          {
            "name": "string",
            "priceMinor": 0
          }
        ],
        "priceMinor": 0,
        "platforms": [
          "windows"
        ],
        "region": "string",
        "status": "undetected",
        "instantDelivery": false,
        "keyInstructions": "string",
        "postPurchaseMessage": "string",
        "maxPerOrder": 1,
        "needsGame": false,
        "downloadLimit": 1,
        "stock": 0,
        "turnaroundDays": 1,
        "discordRoleName": "string"
      }),
    });
    if (!res.ok) throw new Error((await res.json()).detail);
    const data = await res.json();
    import os, requests
    
    res = requests.request(
        "PUT",
        "https://api.shopfa.st/v1/store/product-presets/string",
        headers={"Authorization": f"Bearer {os.environ['SHOPFAST_API_KEY']}"},
        json={
          "name": "string",
          "description": "string",
          "icon": "key",
          "type": "file",
          "titleTemplate": "string",
          "shortDescription": "string",
          "descriptionMd": "string",
          "tags": [
            "string"
          ],
          "options": [
            {
              "name": "string",
              "priceMinor": 0
            }
          ],
          "priceMinor": 0,
          "platforms": [
            "windows"
          ],
          "region": "string",
          "status": "undetected",
          "instantDelivery": False,
          "keyInstructions": "string",
          "postPurchaseMessage": "string",
          "maxPerOrder": 1,
          "needsGame": False,
          "downloadLimit": 1,
          "stock": 0,
          "turnaroundDays": 1,
          "discordRoleName": "string"
        },
    )
    res.raise_for_status()
    data = res.json()
    req, _ := http.NewRequest("PUT", "https://api.shopfa.st/v1/store/product-presets/string", strings.NewReader(`{
      "name": "string",
      "description": "string",
      "icon": "key",
      "type": "file",
      "titleTemplate": "string",
      "shortDescription": "string",
      "descriptionMd": "string",
      "tags": [
        "string"
      ],
      "options": [
        {
          "name": "string",
          "priceMinor": 0
        }
      ],
      "priceMinor": 0,
      "platforms": [
        "windows"
      ],
      "region": "string",
      "status": "undetected",
      "instantDelivery": false,
      "keyInstructions": "string",
      "postPurchaseMessage": "string",
      "maxPerOrder": 1,
      "needsGame": false,
      "downloadLimit": 1,
      "stock": 0,
      "turnaroundDays": 1,
      "discordRoleName": "string"
    }`))
    req.Header.Set("Authorization", "Bearer "+os.Getenv("SHOPFAST_API_KEY"))
    req.Header.Set("Content-Type", "application/json")
    res, err := http.DefaultClient.Do(req)
    Try it with your key

    Use a test key on a development store. The key stays in this tab (sessionStorage) and is sent only to the base URL above.

    Delete your preset, or bring a built-in one back to ShopFast's version

    DELETE/v1/store/product-presets/{presetKey}

    Or name the store: DELETE /v1/stores/{storeId}/product-presets/{presetKey}

    catalog:writerole: catalog:writeresetProductPreset

    Parameters

    • presetKeystringpathrequired

    Response Ok

    • okbooleanrequired

    Example

    curl -X DELETE "https://api.shopfa.st/v1/store/product-presets/string" \
      -H "Authorization: Bearer $SHOPFAST_API_KEY"
    const res = await fetch('https://api.shopfa.st/v1/store/product-presets/string', {
      method: 'DELETE',
      headers: {
        Authorization: `Bearer ${process.env.SHOPFAST_API_KEY}`,
      },
    });
    if (!res.ok) throw new Error((await res.json()).detail);
    const data = await res.json();
    import os, requests
    
    res = requests.request(
        "DELETE",
        "https://api.shopfa.st/v1/store/product-presets/string",
        headers={"Authorization": f"Bearer {os.environ['SHOPFAST_API_KEY']}"},
    )
    res.raise_for_status()
    data = res.json()
    req, _ := http.NewRequest("DELETE", "https://api.shopfa.st/v1/store/product-presets/string", nil)
    req.Header.Set("Authorization", "Bearer "+os.Getenv("SHOPFAST_API_KEY"))
    res, err := http.DefaultClient.Do(req)
    Try it with your key

    Use a test key on a development store. The key stays in this tab (sessionStorage) and is sent only to the base URL above.

    Make it the preset "New product" opens with (or stop)

    POST/v1/store/product-presets/{presetKey}/default

    Or name the store: POST /v1/stores/{storeId}/product-presets/{presetKey}/default

    catalog:writerole: catalog:writesetDefaultProductPreset

    Parameters

    • presetKeystringpathrequired

    Body

    • isDefaultbooleanrequired

    Response SetDefaultProductPresetResponse

    • presetsProductPreset[]required

    Example

    curl -X POST "https://api.shopfa.st/v1/store/product-presets/string/default" \
      -H "Authorization: Bearer $SHOPFAST_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
      "isDefault": false
    }'
    const res = await fetch('https://api.shopfa.st/v1/store/product-presets/string/default', {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.SHOPFAST_API_KEY}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "isDefault": false
      }),
    });
    if (!res.ok) throw new Error((await res.json()).detail);
    const data = await res.json();
    import os, requests
    
    res = requests.request(
        "POST",
        "https://api.shopfa.st/v1/store/product-presets/string/default",
        headers={"Authorization": f"Bearer {os.environ['SHOPFAST_API_KEY']}"},
        json={
          "isDefault": False
        },
    )
    res.raise_for_status()
    data = res.json()
    req, _ := http.NewRequest("POST", "https://api.shopfa.st/v1/store/product-presets/string/default", strings.NewReader(`{
      "isDefault": false
    }`))
    req.Header.Set("Authorization", "Bearer "+os.Getenv("SHOPFAST_API_KEY"))
    req.Header.Set("Content-Type", "application/json")
    res, err := http.DefaultClient.Do(req)
    Try it with your key

    Use a test key on a development store. The key stays in this tab (sessionStorage) and is sent only to the base URL above.

    Create one product per game from a preset (5 games × 4 durations in one go)

    POST/v1/store/product-presets/{presetKey}/bulk

    Or name the store: POST /v1/stores/{storeId}/product-presets/{presetKey}/bulk

    catalog:writerole: catalog:writebulkCreateFromPreset

    Parameters

    • presetKeystringpathrequired

    Body

    • gamesobject[]required
      • gamestringrequired
      • namestring
      • platforms"windows" | "mac" | "linux" | "steam" | "epic" | "battlenet" | "riot" | "ea" | "ubisoft" | "xbox" | "playstation" | "switch" | "android" | "ios" | "web" | "other"[] | null
    • pricesinteger | null[]
    • status"active" | "draft"

    Response BulkPresetResult

    • createdobject[]required
      • idstringrequired
      • namestringrequired
      • slugstringrequired
      • optionsintegerrequired

    Example

    curl -X POST "https://api.shopfa.st/v1/store/product-presets/string/bulk" \
      -H "Authorization: Bearer $SHOPFAST_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
      "games": [
        {
          "game": "string"
        }
      ],
      "prices": [],
      "status": "draft"
    }'
    const res = await fetch('https://api.shopfa.st/v1/store/product-presets/string/bulk', {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.SHOPFAST_API_KEY}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "games": [
          {
            "game": "string"
          }
        ],
        "prices": [],
        "status": "draft"
      }),
    });
    if (!res.ok) throw new Error((await res.json()).detail);
    const data = await res.json();
    import os, requests
    
    res = requests.request(
        "POST",
        "https://api.shopfa.st/v1/store/product-presets/string/bulk",
        headers={"Authorization": f"Bearer {os.environ['SHOPFAST_API_KEY']}"},
        json={
          "games": [
            {
              "game": "string"
            }
          ],
          "prices": [],
          "status": "draft"
        },
    )
    res.raise_for_status()
    data = res.json()
    req, _ := http.NewRequest("POST", "https://api.shopfa.st/v1/store/product-presets/string/bulk", strings.NewReader(`{
      "games": [
        {
          "game": "string"
        }
      ],
      "prices": [],
      "status": "draft"
    }`))
    req.Header.Set("Authorization", "Bearer "+os.Getenv("SHOPFAST_API_KEY"))
    req.Header.Set("Content-Type", "application/json")
    res, err := http.DefaultClient.Do(req)
    Try it with your key

    Use a test key on a development store. The key stays in this tab (sessionStorage) and is sent only to the base URL above.

    Was this page helpful?