STQRY Public API (1.0.0)

Download OpenAPI specification:Download

API documentation for STQRY's public API

Codes

Returns a list of codes for an account

Authorizations:
ApiKeyAuth
query Parameters
page
integer

Page number

per_page
integer [ 1 .. 1000 ]
Default: 30

Number of items per page, max 1000

sort_field
string
Enum: "coupon_code" "valid_from" "valid_to" "id"

Field to sort by

sort_direction
string
Default: "ASC"
Enum: "ASC" "DESC"

Direction to sort by

q
string

Search query

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "data": [
    ]
}

Creates a new code

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required

Code

id
integer
status
string
Enum: "expired" "future" "valid" "invalid" "collection_unlocked" "current" "max_redemptions"
linked_id
integer
linked_type
string
Enum: "Project" "Collection"
string or null (Date)
string or null (Date)
coupon_code
string
redemption_count
integer
project_id
integer
integer or null
integer or null
timezone
string (Timezone)

Timezone as defined by TZInfo

tags
Array of strings (TagList)

Array of tags to help orgainse the codes

string or null (DateTime)
string or null (DateTime)

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "status": "expired",
  • "linked_id": 0,
  • "linked_type": "Project",
  • "valid_from": "2021-01-01",
  • "valid_to": "2021-01-01",
  • "coupon_code": "string",
  • "redemption_count": 0,
  • "project_id": 0,
  • "max_redemptions": 0,
  • "expire_after": 0,
  • "timezone": "string",
  • "tags": [
    ],
  • "created_at": "2017-07-21T17:32:28Z",
  • "updated_at": "2017-07-21T17:32:28Z"
}

Response samples

Content type
application/json
{
  • "code": {
    }
}

Returns a single code

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the Code to retrieve

Responses

Response samples

Content type
application/json
{
  • "code": {
    }
}

Updates an existing code

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the Code to retrieve

Request Body schema: application/json
required

Code

id
integer
status
string
Enum: "expired" "future" "valid" "invalid" "collection_unlocked" "current" "max_redemptions"
linked_id
integer
linked_type
string
Enum: "Project" "Collection"
string or null (Date)
string or null (Date)
coupon_code
string
redemption_count
integer
project_id
integer
integer or null
integer or null
timezone
string (Timezone)

Timezone as defined by TZInfo

tags
Array of strings (TagList)

Array of tags to help orgainse the codes

string or null (DateTime)
string or null (DateTime)

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "status": "expired",
  • "linked_id": 0,
  • "linked_type": "Project",
  • "valid_from": "2021-01-01",
  • "valid_to": "2021-01-01",
  • "coupon_code": "string",
  • "redemption_count": 0,
  • "project_id": 0,
  • "max_redemptions": 0,
  • "expire_after": 0,
  • "timezone": "string",
  • "tags": [
    ],
  • "created_at": "2017-07-21T17:32:28Z",
  • "updated_at": "2017-07-21T17:32:28Z"
}

Response samples

Content type
application/json
{
  • "code": {
    }
}

Updates an existing code

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the Code to retrieve

Request Body schema: application/json
required

Code

id
integer
status
string
Enum: "expired" "future" "valid" "invalid" "collection_unlocked" "current" "max_redemptions"
linked_id
integer
linked_type
string
Enum: "Project" "Collection"
string or null (Date)
string or null (Date)
coupon_code
string
redemption_count
integer
project_id
integer
integer or null
integer or null
timezone
string (Timezone)

Timezone as defined by TZInfo

tags
Array of strings (TagList)

Array of tags to help orgainse the codes

string or null (DateTime)
string or null (DateTime)

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "status": "expired",
  • "linked_id": 0,
  • "linked_type": "Project",
  • "valid_from": "2021-01-01",
  • "valid_to": "2021-01-01",
  • "coupon_code": "string",
  • "redemption_count": 0,
  • "project_id": 0,
  • "max_redemptions": 0,
  • "expire_after": 0,
  • "timezone": "string",
  • "tags": [
    ],
  • "created_at": "2017-07-21T17:32:28Z",
  • "updated_at": "2017-07-21T17:32:28Z"
}

Response samples

Content type
application/json
{
  • "code": {
    }
}

Deletes an existing code

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the Code to delete

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

Collections

Returns a list of collections for an account

Authorizations:
ApiKeyAuth
query Parameters
page
integer

Page number

per_page
integer [ 1 .. 1000 ]
Default: 30

Number of items per page, max 1000

sort_field
string
Enum: "id" "name" "created_at" "updated_at"

Field to sort by

sort_direction
string
Default: "ASC"
Enum: "ASC" "DESC"

Direction to sort by

q
string

Search query

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "data": [
    ]
}

Returns a single collection

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the Collection to retrieve

Responses

Response samples

Content type
application/json
{
  • "collection": {
    }
}

MediaItems

Returns a list of media_items for an account

Authorizations:
ApiKeyAuth
query Parameters
page
integer

Page number

per_page
integer [ 1 .. 1000 ]
Default: 30

Number of items per page, max 1000

sort_field
string
Enum: "id" "name" "created_at" "updated_at"

Field to sort by

sort_direction
string
Default: "ASC"
Enum: "ASC" "DESC"

Direction to sort by

q
string

Search query

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "data": [
    ]
}

Returns a single media_item

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the MediaItem to retrieve

Responses

Response samples

Content type
application/json
{
  • "media_item": {
    }
}

Projects

Returns a list of projects for an account

Authorizations:
ApiKeyAuth
query Parameters
page
integer

Page number

per_page
integer [ 1 .. 1000 ]
Default: 30

Number of items per page, max 1000

sort_field
string
Enum: "id" "name" "created_at" "updated_at"

Field to sort by

sort_direction
string
Default: "ASC"
Enum: "ASC" "DESC"

Direction to sort by

q
string

Search query

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "data": [
    ]
}

Returns a single project

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the Project to retrieve

Responses

Response samples

Content type
application/json
{
  • "project": {
    }
}

Screens

Returns a list of screens for an account

Authorizations:
ApiKeyAuth
query Parameters
page
integer

Page number

per_page
integer [ 1 .. 1000 ]
Default: 30

Number of items per page, max 1000

sort_field
string
Enum: "id" "name" "created_at" "updated_at"

Field to sort by

sort_direction
string
Default: "ASC"
Enum: "ASC" "DESC"

Direction to sort by

q
string

Search query

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "data": [
    ]
}

Returns a single screen

Authorizations:
ApiKeyAuth
path Parameters
id
required
integer

ID of the Screen to retrieve

Responses

Response samples

Content type
application/json
{
  • "screen": {
    }
}

stqry