Slyk
  • Introduction
  • Understanding Slyk
    • Before you Start
    • Core Concepts
    • Funding/Withdrawal Methods
  • Developing with Slyk
    • Step-by-step development guide
      • Authentication
      • Wallet
      • Catalog
      • Checkout (coming soon)
      • Growth tools (coming soon)
    • SDKs
      • Server SDK (Node.js)
        • Methods
      • Third party SDK's
  • API Reference
    • Using your API Key
    • Endpoints
      • Wallet
      • Transaction
      • Address
      • Asset
      • Rate
      • PaymentMethod
      • Movement
      • User
      • Invite
      • Category
      • Order
      • Product
      • Question
      • Task
      • TaxRate
    • Webhooks
      • Store
      • Transaction
      • User
    • Models
  • Setup Guides
    • PayPal Configuration
      • Verifying webhook
      • Webhook configuration
    • Stripe Configuration
      • Verifying endpoints
    • Coinbase Configuration
Powered by GitBook
On this page
  • Module endpoints
  • DELETE /categories/:id
  • GET /categories
  • GET /categories/:id
  • PATCH /categories/:id
  • POST /categories
  • POST /categories/:id/reorder

Was this helpful?

  1. API Reference
  2. Endpoints

Category

PreviousInviteNextOrder

Last updated 2 years ago

Was this helpful?

Module endpoints

  • ​

  • ​​

  • ​​

  • ​​

  • ​​

  • ​

DELETE /categories/:id

DELETE http://api.slyk.io/categories/:id

Deletes the category with given id.

204 No Content

GET /categories

GET https://api.slyk.io/categories

Returns a paginated list of categories.

Name

Type

Example

availableProducts

custom

filter[availableProducts]=true

description

ilike

filter[description]=foo

id

= in nin

filter[id]=7938e446-1c77-4513-8cb0-8b1f2e9f47b9

order

=

gte lte

filter[order]=gte:0.5

title

ilike

filter[title]=foo

visibleProducts

custom

filter[visibleProducts]=true

Name

Example

createdAt

sort=createdAt sort=-createdAt

order

sort=order sort=-order

title

sort=title sort=-title

Name

Description

Example

size

Defines the number of results per page. Default = 30.

page[size]=2

number

Defines the number of the page to retrieve. Default = 1

page[number]=2

{
  "data": [
    {
      "createdAt": "2020-08-10T10:00:00.000Z",
      "customData": {},
      "description": "Category with music related things",
      "id": "7938e446-1c77-4513-8cb0-8b1f2e9f47b8",
      "imageUrl": "http://slyk.io/music.png",
      "title": "Music",
      "updatedAt": "2020-08-10T10:00:00.000Z"
    },
    {
      "createdAt": "2020-08-10T11:00:00.000Z",
      "customData": {},
      "description": "Category with clothes",
      "id": "7938e446-1c77-4513-8cb0-8b1f2e9f47b9",
      "imageUrl": "http://slyk.io/clothes.png",
      "title": "Clothes",
      "updatedAt": "2020-08-10T11:00:00.000Z"
    }
  ],
  "total": 2
}

GET /categories/:id

GET https://api.slyk.io/categories/:id‌

Gets the category details of the given id.

{
  "data": {
    "createdAt": "2020-08-10T10:00:00.000Z",
    "customData": {},
    "description": "Category with music related things",
    "id": "7938e446-1c77-4513-8cb0-8b1f2e9f47b9",
    "imageUrl": "http://slyk.io/music.png",
    "title": "Music",
    "updatedAt": "2020-08-10T10:00:00.000Z"
  }
}

PATCH /categories/:id

PATCH https://api.slyk.io/categories/:id

Patches the category details of the given id.

Field

Type

Required

Description

customData

object

false

Can store any additional information about the category.

description

string

false

Category description.

image

string

false

Category image.

order

string

false

Category order value.

title

string

false

Category title.

{
  "description": "foobiz",
  "image": "foobar.png",
  "title": "foobar"
}
{
  "data": {
    "createdAt": "2020-08-10T10:00:00.000Z",
    "customData": {},
    "description": "Category with music related things",
    "id": "7938e446-1c77-4513-8cb0-8b1f2e9f47b9",
    "imageUrl": "http://slyk.io/music.png",
    "title": "Music",
    "updatedAt": "2020-08-10T11:00:00.000Z"
  }
}

POST /categories

POST https://api.slyk.io/categories

Creates a new category.

Field

Type

Required

Description

customData

object

false

Can store any additional information about the category.

description

string

false

Category description.

image

string

false

Category image.

order

string

false

Category order value.

title

string

true

Category title.

{
  "description": "foobiz",
  "image": "foobar.png",
  "title": "foobar"
}
{
  "data": {
    "createdAt": "2020-08-10T10:00:00.000Z",
    "customData": {},
    "description": "Category with music related things",
    "id": "7938e446-1c77-4513-8cb0-8b1f2e9f47b9",
    "imageUrl": "http://slyk.io/music.png",
    "title": "Music",
    "updatedAt": "2020-08-10T10:00:00.000Z"
  }
}

POST /categories/:id/reorder

POST http://api.slyk.io/categories/:id/reorder

Reorders the category with the given id.

Field

Type

Required

Description

subsequentId

string

false

Subsequent category identifier.

{
  "subsequentId": "174c3e0d-226f-443a-a010-12b2140de03c"
}

204 No Content

DELETE /categories/:id
GET /categories
GET /categories/:id
PATCH /categories/:id
POST /categories
POST /categories/:id/reorder