Labels

Manage your subscribers labels

Get project label keys

Returns all label keys for project

GEThttps://api.pushpushgo.com/core/projects/{project}/labels/keys
Authorization
Path parameters
project*string
Header parameters
Response
Body
keysarray of string
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/keys', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "keys": [
    "text"
  ]
}

Get key labels

Returns all labels for a key

GEThttps://api.pushpushgo.com/core/projects/{project}/labels/key-labels
Authorization
Path parameters
project*string
Header parameters
Response
Body
labelsarray of string
totalnumber
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/key-labels', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "labels": [
    "text"
  ],
  "total": 0
}

Get subscriber labels

Returns all labels assigned to subscriber

GEThttps://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}
Authorization
Path parameters
project*string
subscriber*string
Header parameters
Response
Body
labelsarray of object
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "labels": [
    {
      "key": "text",
      "value": "text",
      "expiresAt": "text"
    }
  ]
}

Append label to subscriber

This action is asynchronous append action may take a while to process. Returns with 201 HTTP state

POSThttps://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/append
Authorization
Path parameters
project*string
subscriber*string
Header parameters
Body
keystring
valuestring
expiresAtstring
Response

Empty body

Body
any
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/append', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "message": "input command validation failed",
  "errors": [
    "filed \"name\" expected to be string got number",
    "filed \"age\" expected to be number got string"
  ]
}

Rewrite label by key on subscriber

This action is asynchronous set action may take a while to process. Returns with 201 HTTP state

POSThttps://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/rewrite
Authorization
Path parameters
project*string
subscriber*string
Header parameters
Body
keystring
valuestring
expiresAtstring
Response

Empty body

Body
any
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/rewrite', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "message": "input command validation failed",
  "errors": [
    "filed \"name\" expected to be string got number",
    "filed \"age\" expected to be number got string"
  ]
}

Remove label from subscriber

This action is asynchronous remove action may take a while to process. Returns with 201 HTTP state

POSThttps://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/remove
Authorization
Path parameters
project*string
subscriber*string
Header parameters
Body
keystring
valuestring
Response

Empty body

Body
any
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/remove', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "message": "input command validation failed",
  "errors": [
    "filed \"name\" expected to be string got number",
    "filed \"age\" expected to be number got string"
  ]
}

Append label to subscriber bulk

This action is asynchronous append action may take a while to process. Returns with 201 HTTP state

POSThttps://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/append/bulk
Authorization
Path parameters
project*string
subscriber*string
Header parameters
Body
itemsarray of object
Response

Empty body

Body
any
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/append/bulk', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "message": "input command validation failed",
  "errors": [
    "filed \"name\" expected to be string got number",
    "filed \"age\" expected to be number got string"
  ]
}

Rewrite label by key on subscriber bulk

This action is asynchronous set action may take a while to process. Returns with 201 HTTP state

POSThttps://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/rewrite/bulk
Authorization
Path parameters
project*string
subscriber*string
Header parameters
Body
itemsarray of object
Response

Empty body

Body
any
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/rewrite/bulk', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "message": "input command validation failed",
  "errors": [
    "filed \"name\" expected to be string got number",
    "filed \"age\" expected to be number got string"
  ]
}

Remove label from subscriber bulk

This action is asynchronous remove action may take a while to process. Returns with 201 HTTP state

POSThttps://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/remove/bulk
Authorization
Path parameters
project*string
subscriber*string
Header parameters
Body
itemsarray of object

Bulk items

Response

Empty body

Body
any
Request
const response = await fetch('https://api.pushpushgo.com/core/projects/{project}/labels/subscribers/{subscriber}/remove/bulk', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "message": "input command validation failed",
  "errors": [
    "filed \"name\" expected to be string got number",
    "filed \"age\" expected to be number got string"
  ]
}

Last updated