Collections Quickstart

Using the Appollo Collections methods

Getting started with collections

A commonly used API is the Collections API. A collection is a group of products that are commonly displayed together. An example is "Summer clothing" or "Streetwear".

If your app interacts with a merchant's collections, you can use our various methods to create, read, update and delete collections.

When creating a collection, you should use the collection object structure.

The methods you can use for collections are the following:

const Appollo = require("appollo");
const appollo = new Appollo(apiKey, apiSecret);

appollo.getCollections(merchantId, limit, page)
.then(res => console.log(res))
// Get a list of collections from a merchants store

appollo.getCollection(merchantId, collectionId)
.then(res => console.log(res))
// Get a particular collection from a merchant store

appollo.createCollection(merchantId, collection)
.then(res => console.log(res))
// Create a collection in a merchant store

appollo.updateCollection(merchantId, collection, collectionID)
.then(res => console.log(res))
// Update a collection within a merchant store

appollo.deleteCollection(merchantId, collectionID)
.then(res => console.log(res))
// Delete a collection within a merchant store

appollo.addProductsToCollection(merchantId, products, collectionID)
.then(res => console.log(res))
// Add a list of products to a collection

appollo.removeProductsFromCollection(merchantId, products, collectionID)
.then(res => console.log(res))
// Remove a list of products from a collection

Did this page help you?