Tags
Working with tags.
List Tags
GET /v1/tags
List the Application tags.
Return Type
array<Tags>
Rate limit cost
Each call to this endpoint deducts 1 credit from your request bucket.
Scopes
This endpoint is only available for users with scope APP::MISC.
<?php
// Instantiate a GuzzleHttp client
$client = new \GuzzleHttp\Client();
// Make the request
$response = $client->request("GET", "https://public-api.bladepro.io/v1/tags", [
"headers" => [
"Content-Type" => "application/json",
"Access-Token" => "my-token-from-login",
],
]);
// Process the response
$responseBody = json_decode($response->getBody(), true);require 'rest-client'
require 'json'
# Make the request
response = RestClient.get 'https://public-api.bladepro.io/v1/tags', {
access_token: 'my-token-from-login',
content_type: :json,
accept: :json
}
# Process the response
puts response.body// Require the node HTTP module
var request = require("request");
// Make the request
request({
method: "GET",
json: true,
uri: "https://public-api.bladepro.io/v1/tags",
headers: {
"Access-Token": "my-token-from-login",
"Content-Type": "application/json",
},
(error, response, body) => {
// Process the response
console.log(body);
},
});# Make the request
curl --location --request GET 'https://public-api.bladepro.io/v1/tags' \
--header 'Content-Type: application/json' \
--header 'Access-Token: my-token-from-login'Example result:
{
"meta": {
"request_reference": "235chjz9h-c893v86",
"paging": {
"page": 1,
"records": 1,
"per_page": 250,
"total_records": 1,
"total_pages": 1
}
},
"data": [
{
"id": 1,
"name": "Processed",
"shortcode": "PROCESSED",
"description": "Marked a as processed by XYZ system",
"created": "2019-11-25T14:52:56.000Z"
}
]
}Create Tag
POST /v1/tags
Create a new tag.
Request Body
Return Type
Types for the Request Body
CreateTag (root level)
| Key | Description | Types | Restrictions |
|---|---|---|---|
name | Name of the tag. | string | requirednot nullmin length is 1max length is 50 |
description | Description of the tag. | string | requirednot nullmin length is 1max length is 250 |
shortcode | A unique code associated with the tag. | string | requirednot nullmin length is 1max length is 20match is /[a-zA-Z0-9_-]{3,20}/ |
Rate limit cost
Each call to this endpoint deducts 2 credits from your request bucket.
Scopes
This endpoint is only available for users with scope APP::MISC.
<?php
// Instantiate a GuzzleHttp client
$client = new \GuzzleHttp\Client();
// Make the request
$response = $client->request("POST", "https://public-api.bladepro.io/v1/tags", [
"body" => json_encode([
"name" => "Processed",
"description" => "Marked a as processed by XYZ system.",
"shortcode" => "PROCESSED",
]),
"headers" => [
"Content-Type" => "application/json",
"Access-Token" => "my-token-from-login",
],
]);
// Process the response
$responseBody = json_decode($response->getBody(), true);require 'rest-client'
require 'json'
# Make the request
response = RestClient.post 'https://public-api.bladepro.io/v1/tags', {
name: "Processed",
description: "Marked a as processed by XYZ system.",
shortcode: "PROCESSED",
}, {
access_token: 'my-token-from-login',
content_type: :json,
accept: :json
}
# Process the response
puts response.body// Require the node HTTP module
var request = require("request");
// Make the request
request({
method: "POST",
json: true,
uri: "https://public-api.bladepro.io/v1/tags",
body: {
"name": "Processed",
"description": "Marked a as processed by XYZ system.",
"shortcode": "PROCESSED"
},
headers: {
"Access-Token": "my-token-from-login",
"Content-Type": "application/json",
},
(error, response, body) => {
// Process the response
console.log(body);
},
});# Make the request
curl --location --request POST 'https://public-api.bladepro.io/v1/tags' \
--header 'Content-Type: application/json' \
--header 'Access-Token: my-token-from-login' \
--data-raw '{
"name": "Processed",
"description": "Marked a as processed by XYZ system.",
"shortcode": "PROCESSED"
}'Example result:
{
"meta": {
"request_reference": "235chjz9h-c893v86"
},
"data": {
"id": 1,
"name": "Processed",
"shortcode": "PROCESSED",
"description": "Marked a as processed by XYZ system",
"created": "2019-11-25T14:52:56.000Z"
}
}