API ReferenceView as MarkdownOpenAPI

Products

View as Markdown

Products are what the store sells: physical items with weight and delivery, digital downloads, and items with options (size, colour) that change the price. A product sits in a product/ category, can be filtered by grouping/ collections, and can show a page built in the editor below its details. How many are in stock is kept per option in stock lines (/inventory), not on the product.

Endpoints that need a token: the site owner creates it in their admin (Developers > API reference). AI assistants: how to ask the user for one.

33 endpoints in 3 parts: Product, Digital Content, Inventory.

Retrieve a digital product

The download page of a digital product the user bought. Lists the product's files for download; JSON with ?ionic.

User tokenOptional user

Needs the token of a signed-in user.

Path parameters
urlstringRequired

The digital product's URL slug, as in its address on the site.

Returns

Returns the Product object.

Status codes

200 401 500

GET/digital-product/:url
curl -X GET 'http://bulgariandebateassociation.max-media.io/digital-product/{url}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

Export products

Every product as a CSV, with its categories. The same columns as the import template, so it can be edited and imported back.

Admin token

Needs a site admin token.

Returns

Returns the Product object.

Status codes

200 401 500

GET/export-products
curl -X GET 'http://bulgariandebateassociation.max-media.io/export-products?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

Import templates

The CSV template for importing products. Answers a CSV file with the columns POST /import-products-custom reads.

Admin token

Needs a site admin token.

Status codes

200 401

GET/get-import-template
curl -X GET 'http://bulgariandebateassociation.max-media.io/get-import-template?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Import products custom

Imports products from a CSV made from the platform's import template. Multipart CSV upload in the format of GET /get-import-template. Answers { corrupted_products }.

Admin token

Needs a site admin token.

Status codes

200 401 500

POST/import-products-custom
curl -X POST 'http://bulgariandebateassociation.max-media.io/import-products-custom?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "parent_collection": "6543210fedcba98765432100",
  "picture": "6543210fedcba98765432100",
  "about_page": "6543210fedcba98765432100",
  "match_to_option": false,
  "is_color": false,
  "color": "#3557c4",
  "position": 1,
  "items": [
    "6543210fedcba98765432101"
  ],
  "thumbnail": "6543210fedcba98765432100",
  "_id": "6543210fedcba98765432100"
}

Import products shopify

Imports products from a Shopify CSV export. Multipart CSV upload. Answers { corrupted_products }: the rows that could not be imported.

Admin token

Needs a site admin token.

Status codes

200 401 500

POST/import-products-shopify
curl -X POST 'http://bulgariandebateassociation.max-media.io/import-products-shopify?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "parent_collection": "6543210fedcba98765432100",
  "picture": "6543210fedcba98765432100",
  "about_page": "6543210fedcba98765432100",
  "match_to_option": false,
  "is_color": false,
  "color": "#3557c4",
  "position": 1,
  "items": [
    "6543210fedcba98765432101"
  ],
  "thumbnail": "6543210fedcba98765432100",
  "_id": "6543210fedcba98765432100"
}

Import products squarespace

Imports products from a Squarespace CSV export. Multipart CSV upload. Answers { corrupted_products }: the rows that could not be imported.

Admin token

Needs a site admin token.

Status codes

200 401 500

POST/import-products-squarespace
curl -X POST 'http://bulgariandebateassociation.max-media.io/import-products-squarespace?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "parent_collection": "6543210fedcba98765432100",
  "picture": "6543210fedcba98765432100",
  "about_page": "6543210fedcba98765432100",
  "match_to_option": false,
  "is_color": false,
  "color": "#3557c4",
  "position": 1,
  "items": [
    "6543210fedcba98765432101"
  ],
  "thumbnail": "6543210fedcba98765432100",
  "_id": "6543210fedcba98765432100"
}

Import products wix

Imports products from a Wix CSV export, with their categories and pictures. Multipart CSV upload. Categories are created as needed and pictures downloaded from their URLs. Answers { corrupted_products }: the rows that could not be imported.

Admin token

Needs a site admin token.

Status codes

200 401 500

POST/import-products-wix
curl -X POST 'http://bulgariandebateassociation.max-media.io/import-products-wix?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "parent_collection": "6543210fedcba98765432100",
  "picture": "6543210fedcba98765432100",
  "about_page": "6543210fedcba98765432100",
  "match_to_option": false,
  "is_color": false,
  "color": "#3557c4",
  "position": 1,
  "items": [
    "6543210fedcba98765432101"
  ],
  "thumbnail": "6543210fedcba98765432100",
  "_id": "6543210fedcba98765432100"
}

Like or unlike a product

Likes or unlikes a product and notifies its owner. Calling it again takes the like back. Answers { like }: whether it is liked now.

User token

Needs the token of a signed-in user.

Path parameters
idstringRequired

The ID of the product.

Returns

Returns the Product object.

Status codes

200 400 401 404 500

PATCH/product-likes/:id
curl -X PATCH 'http://bulgariandebateassociation.max-media.io/product-likes/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

Find a product by its address

Opens a product in the app (redirects to its app page). For links shared from the app: the website sends the visitor to the product in the app.

Optional user

Works without a token; with a user token the answer is personal.

Path parameters
urlstringRequired

The product's URL slug, as in its address on the site.

Status codes

200 500

GET/product-redirect/:url
curl -X GET 'http://bulgariandebateassociation.max-media.io/product-redirect/{url}?ionic=true'
Response
{
  "zip_code": "example",
  "city": "example",
  "address": "example",
  "contact": "example",
  "email": "jane@example.com",
  "google_app": "example",
  "workhours": "example",
  "logo": "6543210fedcba98765432100",
  "site_name": "Example",
  "domain": "example",
  "stock_domain": "example",
  "isMarket": false,
  "forbidden_collections": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "isInit": false,
  "template": "0000",
  "lang": "en",
  "favicon": "6543210fedcba98765432100",
  "cacheEnabled": false,
  "has_completed_startup_prompt": true,
  "gmb_location": "example",
  "ga_property": "example",
  "site_generated_at": "2026-11-04T12:00:00.000Z",
  "admin_first_opened_at": "2026-11-04T12:00:00.000Z",
  "admin_last_opened_at": "2026-11-04T12:00:00.000Z",
  "allowedComponents": {
    "services": false,
    "products": false,
    "blogposts": false,
    "programs": false
  }
}

Save or unsave a product

Saves or unsaves a product for the signed-in user. Calling it again unsaves.

User token

Needs the token of a signed-in user.

Path parameters
idstringRequired

The ID of the product.

Returns

Returns the Product object.

Status codes

200 400 401 404 500

PATCH/product-saves/:id
curl -X PATCH 'http://bulgariandebateassociation.max-media.io/product-saves/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

List all products

The store's products page, or the products as JSON with ?ionic: filtered by category, price, search and published state, and sorted (?sortBy). Paged with ?skip. Filters: ?collection (a category name), ?minPrice and ?maxPrice, ?origin_address, ?rating, ?published; ?sortBy sets the order. Hidden from visitors whose sign-in or plan does not open the store. Cached for an hour.

User with accessOptional user

Needs a signed-in user whose plan grants access.

Query parameters
publishedstring

true: only products that are published; false: only those that are not.

completedstring

Only products with this completed.

sortBystring

The order of the results.

minPricestring

Only products with a price of at least this.

maxPricestring

Only products with a price of at most this.

collectionstring

Only results in this collection.

origin_addressstring

Only products with this origin address.

skipstring

How many results to skip - for paging.

wherestring

Only products with this where.

ratingstring

Only products with this rating.

Returns

Returns a list of Product objects.

Status codes

200 401 402 404 500

GET/products
curl -X GET 'http://bulgariandebateassociation.max-media.io/products?ionic=true&published=...&completed=...&sortBy=...' \
  -H 'Authorization: Bearer <TOKEN>'
Response
[
  {
    "name": "Example",
    "url": "example-item",
    "static_url": "example-item",
    "ribbon": "example",
    "striked": "example",
    "price": 49.9,
    "description": "Text shown on the site.",
    "product_informations": [
      {
        "name": "Example",
        "description": "Text shown on the site.",
        "_id": "6543210fedcba98765432100"
      }
    ],
    "product_options": [
      {
        "name": "Example",
        "options": [],
        "informations": [],
        "_id": "6543210fedcba98765432100"
      }
    ],
    "published": true,
    "available_for_purchase": true,
    "medias": [
      {
        "media": "6543210fedcba98765432100",
        "gcs_url": "example-item",
        "gcs_480_30_url": "example-item",
        "gcs_720_30_url": "example-item",
        "gcs_1080_30_url": "example-item",
        "duration": 1,
        "vimeo_uri": "example",
        "vimeo_picture": "example",
        "vimeo_url": "example-item",
        "youtube_url": "example-item",
        "youtube_picture": "example",
        "thumbnail": "example",
        "_id": "6543210fedcba98765432100"
      }
    ],
    "collection_id": "6543210fedcba98765432100",
    "grouping": [
      {
        "collection_id": "6543210fedcba98765432100",
        "_id": "6543210fedcba98765432100"
      }
    ],
    "owner_id": "6543210fedcba98765432100",
    "connected_account_owner_id": "6543210fedcba98765432100",
    "qty": 1,
    "origin_address": "example",
    "selected": false,
    "custom_1": "example",
    "custom_2": "example",
    "custom_3": "example",
    "about_page": "6543210fedcba98765432100",
    "is_digital": false,
    "secondary_cta": {
      "show": false,
      "title": "Example",
      "webUrl": "example",
      "appUrl": "example"
    },
    "attached_priceplans": {
      "name": "Example",
      "priceplans": "example"
    }
  }
]

Create a product

Creates a product. url is made from name, so do not send one. Option prices go in the option's text as "Large (+5)": the amount is added to price. Answers 201 with the product. Also creates its stock lines and re-renders the home page. To create it for an account you manage, send on_behalf_of (403 without catalogue rights). In social mode the url gets a number appended and a non-admin's product waits for review.

User token

Needs the token of a signed-in user.

Parameters
namestring

Name of product.

on_behalf_ofstring

The product's on behalf of.

Returns

Returns the Product object.

Status codes

201 400 401 403 500

POST/products
curl -X POST 'http://bulgariandebateassociation.max-media.io/products?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{ "name": "...", "on_behalf_of": "..." }'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

Delete multiple products

Deletes several products, ids comma-separated, with their stock lines. Answers the ids that were deleted.

User token

Needs the token of a signed-in user.

Path parameters
delete_idsstringRequired

The product's delete ids.

Returns

Returns an empty answer on success.

Status codes

200 401 500

DELETE/products-multiple/:delete_ids
curl -X DELETE 'http://bulgariandebateassociation.max-media.io/products-multiple/{delete_ids}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Update multiple products

Applies the same changes (updates) to several products, ids comma-separated. Answers the ids that were changed.

User token

Needs the token of a signed-in user.

Path parameters
patch_idsstringRequired

The product's patch ids.

Parameters
collection_idobjectid

Collection.id.

groupingobject[]

The grouping/ filters it appears under inside its category: each { collection_id }.

updatesstring

The product's updates.

Returns

Returns the Product object.

Status codes

200 400 401 500

PATCH/products-multiple/:patch_ids
curl -X PATCH 'http://bulgariandebateassociation.max-media.io/products-multiple/{patch_ids}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{ "collection_id": "...", "grouping": "...", "updates": "..." }'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

List multiple products

Several products by id, comma-separated. Only each product's name, id and options.

User token

Needs the token of a signed-in user.

Path parameters
product_idsstringRequired

The product's product ids.

Returns

Returns a list of Product objects.

Status codes

200 401 500

GET/products-multiple/:product_ids
curl -X GET 'http://bulgariandebateassociation.max-media.io/products-multiple/{product_ids}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
[
  {
    "name": "Example",
    "url": "example-item",
    "static_url": "example-item",
    "ribbon": "example",
    "striked": "example",
    "price": 49.9,
    "description": "Text shown on the site.",
    "product_informations": [
      {
        "name": "Example",
        "description": "Text shown on the site.",
        "_id": "6543210fedcba98765432100"
      }
    ],
    "product_options": [
      {
        "name": "Example",
        "options": [],
        "informations": [],
        "_id": "6543210fedcba98765432100"
      }
    ],
    "published": true,
    "available_for_purchase": true,
    "medias": [
      {
        "media": "6543210fedcba98765432100",
        "gcs_url": "example-item",
        "gcs_480_30_url": "example-item",
        "gcs_720_30_url": "example-item",
        "gcs_1080_30_url": "example-item",
        "duration": 1,
        "vimeo_uri": "example",
        "vimeo_picture": "example",
        "vimeo_url": "example-item",
        "youtube_url": "example-item",
        "youtube_picture": "example",
        "thumbnail": "example",
        "_id": "6543210fedcba98765432100"
      }
    ],
    "collection_id": "6543210fedcba98765432100",
    "grouping": [
      {
        "collection_id": "6543210fedcba98765432100",
        "_id": "6543210fedcba98765432100"
      }
    ],
    "owner_id": "6543210fedcba98765432100",
    "connected_account_owner_id": "6543210fedcba98765432100",
    "qty": 1,
    "origin_address": "example",
    "selected": false,
    "custom_1": "example",
    "custom_2": "example",
    "custom_3": "example",
    "about_page": "6543210fedcba98765432100",
    "is_digital": false,
    "secondary_cta": {
      "show": false,
      "title": "Example",
      "webUrl": "example",
      "appUrl": "example"
    },
    "attached_priceplans": {
      "name": "Example",
      "priceplans": "example"
    }
  }
]

Update a product

Updates a product. Stock is not set here: it lives in stock lines (PATCH /inventory/:id). Fields outside the allowed list are silently ignored. Changing product_options rebuilds the product's stock lines and removes it from other products' linked_products. Answers the product, with medias as picture URLs rather than ids. 403 unless the owner, an admin or a manager with catalogue rights. In social mode most changes send it back to review.

User token

Needs the token of a signed-in user.

Path parameters
idstringRequired

The ID of the product.

Parameters
convertedPricestring

The product's converted price.

product_optionsobject[]

The choices a buyer makes (Size, Colour): each { name, options: [{ option }] }. An option's text may carry a price change in brackets, "Large (+5)", added to price. Changing the options rebuilds the product's stock lines.

Returns

Returns the Product object.

Status codes

200 400 401 403 404 500

PATCH/products/:id
curl -X PATCH 'http://bulgariandebateassociation.max-media.io/products/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{ "convertedPrice": "...", "product_options": "..." }'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

Delete a product

Deletes a product. Also deletes its stock lines and removes it from other products' linked_products. Answers the deleted product. 403 unless the owner or an admin.

User token

Needs the token of a signed-in user.

Path parameters
idstringRequired

The ID of the product.

Returns

Returns an empty answer on success.

Status codes

200 401 403 404 500

DELETE/products/:id
curl -X DELETE 'http://bulgariandebateassociation.max-media.io/products/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Retrieve a product

A product's first picture. 404 when the product has no picture.

Public

Public - no token needed.

Path parameters
idstringRequired

The ID of the product.

Returns

Returns the Product object.

Status codes

200 404 500

GET/products/:id/media
curl -X GET 'http://bulgariandebateassociation.max-media.io/products/{id}/media?ionic=true'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

Create a product

Uploads a picture to a product (media, form field). Multipart upload; the picture is resized and added to the product's medias.

User token

Needs the token of a signed-in user.

Path parameters
idstringRequired

The ID of the product.

Status codes

200 400 401

POST/products/:id/media
curl -X POST 'http://bulgariandebateassociation.max-media.io/products/{id}/media?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Delete a product

Removes a picture from a product. The media record itself stays in the library.

User token

Needs the token of a signed-in user.

Path parameters
idstringRequired

The ID of the product.

media_idstringRequired

The product's media id.

Returns

Returns an empty answer on success.

Status codes

200 401

DELETE/products/:id/media/:media_id
curl -X DELETE 'http://bulgariandebateassociation.max-media.io/products/{id}/media/{media_id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Retrieve a product

A product's page by its url, or the product as JSON with ?ionic. By url, not id. 404 when there is no such product. Comes with its categories, likes and attached plans. Cached for an hour, except for signed-in visitors.

Optional userPage access

Works without a token; with a user token the answer is personal.

Path parameters
urlstringRequired

The product's URL slug, as in its address on the site.

Query parameters
sessionIdstring

Only products with this session id.

Returns

Returns the Product object.

Status codes

200 401 402 404 500

GET/products/:url
curl -X GET 'http://bulgariandebateassociation.max-media.io/products/{url}?ionic=true&sessionId=...'
Response
{
  "name": "Example",
  "url": "example-item",
  "static_url": "example-item",
  "ribbon": "example",
  "striked": "example",
  "price": 49.9,
  "description": "Text shown on the site.",
  "product_informations": [
    {
      "name": "Example",
      "description": "Text shown on the site.",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "product_options": [
    {
      "name": "Example",
      "options": [],
      "informations": [],
      "_id": "6543210fedcba98765432100"
    }
  ],
  "published": true,
  "available_for_purchase": true,
  "medias": [
    {
      "media": "6543210fedcba98765432100",
      "gcs_url": "example-item",
      "gcs_480_30_url": "example-item",
      "gcs_720_30_url": "example-item",
      "gcs_1080_30_url": "example-item",
      "duration": 1,
      "vimeo_uri": "example",
      "vimeo_picture": "example",
      "vimeo_url": "example-item",
      "youtube_url": "example-item",
      "youtube_picture": "example",
      "thumbnail": "example",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "collection_id": "6543210fedcba98765432100",
  "grouping": [
    {
      "collection_id": "6543210fedcba98765432100",
      "_id": "6543210fedcba98765432100"
    }
  ],
  "owner_id": "6543210fedcba98765432100",
  "connected_account_owner_id": "6543210fedcba98765432100",
  "qty": 1,
  "origin_address": "example",
  "selected": false,
  "custom_1": "example",
  "custom_2": "example",
  "custom_3": "example",
  "about_page": "6543210fedcba98765432100",
  "is_digital": false,
  "secondary_cta": {
    "show": false,
    "title": "Example",
    "webUrl": "example",
    "appUrl": "example"
  },
  "attached_priceplans": {
    "name": "Example",
    "priceplans": "example"
  }
}

Retrieve the digital content

The digital content files. Answers an array of every record.

Admin token

Needs a site admin token.

Returns

Returns the DigitalContent object.

Status codes

200 401 500

GET/digital-content
curl -X GET 'http://bulgariandebateassociation.max-media.io/digital-content?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "type": "example",
  "file": "example",
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Create a digital content

Creates a digital content file. Multipart upload of one file (files). Answers 201 with no body.

Admin token

Needs a site admin token.

Parameters
bodystring

The digital content's body.

Returns

Returns the DigitalContent object.

Status codes

201 400 401 500

POST/digital-content
curl -X POST 'http://bulgariandebateassociation.max-media.io/digital-content?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{ "body": "..." }'
Response
{
  "name": "Example",
  "type": "example",
  "file": "example",
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Retrieve a digital content file

Downloads a digital file, for a user who bought it or when it is free. Answers the file. 401 when the user has not bought a product that includes it.

User token

Needs the token of a signed-in user.

Path parameters
idstringRequired

The ID of the digital content file.

Status codes

200 401 404 500

GET/digital-content-file/:id
curl -X GET 'http://bulgariandebateassociation.max-media.io/digital-content-file/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "type": "example",
  "file": "example",
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Retrieve a digital content

One digital content file. 404 when there is no such record.

Admin token

Needs a site admin token.

Path parameters
idstringRequired

The ID of the digital content.

Returns

Returns the DigitalContent object.

Status codes

200 401 404 500

GET/digital-content/:id
curl -X GET 'http://bulgariandebateassociation.max-media.io/digital-content/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "type": "example",
  "file": "example",
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Update a digital content

Updates a digital content file. Fields outside the allowed list are silently ignored. Answers the updated record, or 404.

Admin token

Needs a site admin token.

Path parameters
idstringRequired

The ID of the digital content.

Returns

Returns the DigitalContent object.

Status codes

200 400 401 404 500

PATCH/digital-content/:id
curl -X PATCH 'http://bulgariandebateassociation.max-media.io/digital-content/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "name": "Example",
  "type": "example",
  "file": "example",
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Delete a digital content

Deletes a digital content file. Answers the deleted record, or 404. Records that point to it are not changed.

Admin token

Needs a site admin token.

Path parameters
idstringRequired

The ID of the digital content.

Returns

Returns an empty answer on success.

Status codes

200 401 404 500

DELETE/digital-content/:id
curl -X DELETE 'http://bulgariandebateassociation.max-media.io/digital-content/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Retrieve the inventory

The store's stock: one line per product option, with how many are in stock. Each line with its product's name, picture, category and price.

Admin token

Needs a site admin token.

Returns

Returns the Inventory object.

Status codes

200 401 500

GET/inventory
curl -X GET 'http://bulgariandebateassociation.max-media.io/inventory?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "product": "6543210fedcba98765432100",
  "option": "example",
  "quantity": 0,
  "sku": "example",
  "track": false,
  "trackSku": false,
  "name": {},
  "media": {},
  "category": {},
  "price": {},
  "status": {},
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Create an inventory

Creates a stock line. Stock lines are normally made by product create and update; this adds one by hand. Answers 201.

Admin token

Needs a site admin token.

Status codes

201 400 401 500

POST/inventory
curl -X POST 'http://bulgariandebateassociation.max-media.io/inventory?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Retrieve an inventory

The first stock line of a product, by the product's id. The id is a PRODUCT's id, not a stock line's: a product with options has one line per option - read GET /inventory or GET /inventory/:product_id/:option for those. 404 when the product has no stock line. Reads no token.

Public

Public - no token needed.

Path parameters
idstringRequired

The ID of the inventory.

Returns

Returns the Inventory object.

Status codes

200 404 500

GET/inventory/:id
curl -X GET 'http://bulgariandebateassociation.max-media.io/inventory/{id}?ionic=true'
Response
{
  "product": "6543210fedcba98765432100",
  "option": "example",
  "quantity": 0,
  "sku": "example",
  "track": false,
  "trackSku": false,
  "name": {},
  "media": {},
  "category": {},
  "price": {},
  "status": {},
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Update an inventory

Sets the stock of one product option: quantity in stock, SKU, and whether it is tracked. The id is the stock line's (_id from GET /inventory). Send only what changes; a quantity turns tracking on unless track is sent too. To add to the stock, read the line's quantity first and send the new total. Fields outside quantity, track, sku and trackSku are ignored. Answers the updated line, or 404.

Admin token

Needs a site admin token.

Path parameters
idstringRequired

The ID of the inventory.

Returns

Returns the Inventory object.

Status codes

200 400 401 404 500

PATCH/inventory/:id
curl -X PATCH 'http://bulgariandebateassociation.max-media.io/inventory/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'
Response
{
  "product": "6543210fedcba98765432100",
  "option": "example",
  "quantity": 0,
  "sku": "example",
  "track": false,
  "trackSku": false,
  "name": {},
  "media": {},
  "category": {},
  "price": {},
  "status": {},
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}

Delete an inventory

Deletes a stock line. Answers the deleted record, or 404. Records that point to it are not changed.

Admin token

Needs a site admin token.

Path parameters
idstringRequired

The ID of the inventory.

Returns

Returns an empty answer on success.

Status codes

200 401 404 500

DELETE/inventory/:id
curl -X DELETE 'http://bulgariandebateassociation.max-media.io/inventory/{id}?ionic=true' \
  -H 'Authorization: Bearer <TOKEN>'

Retrieve an inventory

The stock line of one option of a product: how many are in stock, its id to change it. Answers { track: false } when the product's stock is not tracked; 404 when there is no line for that option.

Public

Public - no token needed.

Path parameters
product_idstringRequired

The inventory's product id.

optionstringRequired

The product option this stock line is for ("Red / L").

Returns

Returns the Inventory object.

Status codes

200 404 500

GET/inventory/:product_id/:option
curl -X GET 'http://bulgariandebateassociation.max-media.io/inventory/{product_id}/{option}?ionic=true'
Response
{
  "product": "6543210fedcba98765432100",
  "option": "example",
  "quantity": 0,
  "sku": "example",
  "track": false,
  "trackSku": false,
  "name": {},
  "media": {},
  "category": {},
  "price": {},
  "status": {},
  "_id": "6543210fedcba98765432100",
  "updatedAt": "2026-11-04T12:00:00.000Z",
  "createdAt": "2026-11-04T12:00:00.000Z"
}
↑↓ Navigate↵ GoEsc Close