Cachet Documentation

Cachet Developer Hub

Beautiful & simple service statuses. The open source status page system, for everyone.

Get Started
Suggest Edits

/ping

Test that the API is responding to your requests.

 
gethttps://demo.cachethq.io/api/v1/ping
curl --request GET \
  --url https://demo.cachethq.io/api/v1/ping
var request = require("request");

var options = { method: 'GET', url: 'https://demo.cachethq.io/api/v1/ping' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/ping")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/ping");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/ping"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{ "data": "Pong!" }
 
Suggest Edits

/version

Get the Cachet version.

 
gethttps://demo.cachethq.io/api/v1/version
curl --request GET \
  --url https://demo.cachethq.io/api/v1/version
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/version' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/version")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/version");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/version"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "meta": {
        "on_latest": true,
        "latest": {
            "tag_name": "v2.3.10",
            "prelease": false,
            "draft": false
        }
    },
    "data": "2.3.11-dev"
}
 

Availability

The version endpoint is available from Cachet 2.2.0 onwards.

Suggest Edits

/components

Get all components.

 

Header Auth

 Authentication is required for this endpoint.
gethttps://demo.cachethq.io/api/v1/components
curl --request GET \
  --url https://demo.cachethq.io/api/v1/components
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/components' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/components");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "meta": {
        "pagination": {
            "total": 1,
            "count": 1,
            "per_page": 20,
            "current_page": 1,
            "total_pages": 1,
            "links": {
                "next_page": null,
                "previous_page": null
            }
        }
    },
    "data": [
        {
            "id": 1,
            "name": "API",
            "description": "This is the Cachet API.",
            "link": "",
            "status": 1,
            "order": 0,
            "group_id": 0,
            "created_at": "2015-07-24 14:42:10",
            "updated_at": "2015-07-24 14:42:10",
            "deleted_at": null,
            "status_name": "Operational",
          	"tags": [
            		"slug-of-tag": "Tag Name"
            ]
        }
    ]
}
 

Searchable Keys

Advanced API Usage

Please refer to the Advanced API Usage guide.

  • id
  • name
  • status
  • group_id
  • enabled
Suggest Edits

/components/:component

Get a single component.

 
gethttps://demo.cachethq.io/api/v1/components/component
curl --request GET \
  --url https://demo.cachethq.io/api/v1/components/component
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/components/component' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/component")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/components/component");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/component"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "name": "API",
        "description": "This is the Cachet API.",
        "link": "",
        "status": 1,
        "order": 0,
        "group_id": 0,
        "created_at": "2015-07-24 14:42:10",
        "updated_at": "2015-07-24 14:42:10",
        "deleted_at": null,
        "status_name": "Operational",
        "tags": [
        		"slug-of-tag": "Tag Name"
        ]
    }
}

Path Params

component
int32
required

Component ID

 
Suggest Edits

/components

Create a new component.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1/components
curl --request POST \
  --url https://demo.cachethq.io/api/v1/components
var request = require("request");

var options = { method: 'POST',
  url: 'https://demo.cachethq.io/api/v1/components' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1/components");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "name": "Component Name",
        "description": "Description",
        "link": "",
        "status": 1,
        "order": 0,
        "group_id": 0,
        "created_at": "2015-08-01 12:00:00",
        "updated_at": "2015-08-01 12:00:00",
        "deleted_at": null,
        "status_name": "Operational",
        "tags": [
            "slug-of-tag": "Tag Name"
        ]
    }
}

Body Params

name
string
required

Name of the component

description
string

Description of the component

status
int32
required

Status of the component; 1-4

link
string

A hyperlink to the component

order
int32

Order of the component

group_id
int32

The group id that the component is within

enabled
boolean

Whether the component is enabled

 
Suggest Edits

/components/:component

Update a component.

 

Header Auth

 Authentication is required for this endpoint.
puthttps://demo.cachethq.io/api/v1/components/component
curl --request PUT \
  --url https://demo.cachethq.io/api/v1/components/component
var request = require("request");

var options = { method: 'PUT',
  url: 'https://demo.cachethq.io/api/v1/components/component' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/component")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://demo.cachethq.io/api/v1/components/component");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/component"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "name": "Component Name",
        "description": "Description",
        "link": "",
        "status": 1,
        "order": 0,
        "group_id": 0,
        "created_at": "2015-08-01 12:00:00",
        "updated_at": "2015-08-01 12:00:00",
        "deleted_at": null,
        "status_name": "Operational",
        "tags": [
            "slug-of-tag": "Tag Name"
        ]
    }
}

Path Params

component
int32
required

Component ID

Body Params

name
string

Name of the component

status
int32

Status of the component; 1-4

link
string

A hyperlink to the component

order
int32

Order of the component

group_id
int32

The group id that the component is within

enabled
boolean

Whether the component is enabled

 
Suggest Edits

/components/:component

Delete a component.

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://demo.cachethq.io/api/v1/components/component
curl --request DELETE \
  --url https://demo.cachethq.io/api/v1/components/component
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://demo.cachethq.io/api/v1/components/component' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/component")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://demo.cachethq.io/api/v1/components/component");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/component"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

component
int32
required

Component ID

 
Suggest Edits

/components/groups

Get all Component Groups.

 
gethttps://demo.cachethq.io/api/v1/components/groups
curl --request GET \
  --url https://demo.cachethq.io/api/v1/components/groups
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/components/groups' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/groups")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/components/groups");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/groups"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "meta": {
        "pagination": {
            "total": 1,
            "count": 1,
            "per_page": 20,
            "current_page": 1,
            "total_pages": 1,
            "links": {
                "next_page": null,
                "previous_page": null
            }
        }
    },
    "data": [
        {
            "id": 1,
            "name": "Websites",
            "created_at": "2015-11-07 13:30:04",
            "updated_at": "2015-11-07 13:30:04",
            "order": 1,
          	"collapsed": 0
        }
    ]
}
 

Searchable Keys

Advanced API Usage

Please refer to the Advanced API Usage guide.

  • id
  • name
  • collapsed
  • visible
Suggest Edits

/components/groups/:group

Get a Component Group.

 
gethttps://demo.cachethq.io/api/v1/components/groups/group
curl --request GET \
  --url https://demo.cachethq.io/api/v1/components/groups/group
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/components/groups/group' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/groups/group")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/components/groups/group");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/groups/group"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "name": "Websites",
        "created_at": "2015-11-07 13:30:04",
        "updated_at": "2015-11-07 13:30:04",
        "order": 1,
        "collapsed": 0
    }
}

Path Params

group
int32
required

Component Group ID

 
Suggest Edits

/components/groups

Create a new Component Group.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1/components/groups
curl --request POST \
  --url https://demo.cachethq.io/api/v1/components/groups
var request = require("request");

var options = { method: 'POST',
  url: 'https://demo.cachethq.io/api/v1/components/groups' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/groups")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1/components/groups");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/groups"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
    "data": {
        "name": "Foo",
        "order": 1,
      	"collapsed": 0,
        "updated_at": "2015-11-07 16:35:13",
        "created_at": "2015-11-07 16:35:13",
        "id": 2
    }
}

Body Params

name
string
required

Name of the component group

order
int32

Order of the component group

collapsed
int32

Collapse the group? 0 = No. 1 = Yes. 2 = If a component is not Operational.

 
Suggest Edits

/components/groups/:group

Update a Component Group.

 

Header Auth

 Authentication is required for this endpoint.
puthttps://demo.cachethq.io/api/v1/components/groups/group
curl --request PUT \
  --url https://demo.cachethq.io/api/v1/components/groups/group
var request = require("request");

var options = { method: 'PUT',
  url: 'https://demo.cachethq.io/api/v1/components/groups/group' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/groups/group")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://demo.cachethq.io/api/v1/components/groups/group");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/groups/group"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned
{
    "data": {
        "name": "Foo",
        "order": 1,
        "collapsed": 0,
        "updated_at": "2015-11-07 16:35:13",
        "created_at": "2015-11-07 16:35:13",
        "id": 2
    }
}

Path Params

group
int32
required

Component Group ID

Body Params

name
string

Name of the component group

order
int32

Order of the group

collapsed
int32

Collapse the group? 0 = No. 1 = Yes. 2 = If a component is not Operational.

 
Suggest Edits

/components/groups/:group

Delete a Component Group.

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://demo.cachethq.io/api/v1/components/groups/group
curl --request DELETE \
  --url https://demo.cachethq.io/api/v1/components/groups/group
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://demo.cachethq.io/api/v1/components/groups/group' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/components/groups/group")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://demo.cachethq.io/api/v1/components/groups/group");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/components/groups/group"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

group
string
required

Component Group ID

 
Suggest Edits

/incidents

Get all Incidents.

 
gethttps://demo.cachethq.io/api/v1/incidents
curl --request GET \
  --url https://demo.cachethq.io/api/v1/incidents
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/incidents' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/incidents")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/incidents");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/incidents"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "meta": {
        "pagination": {
            "total": 1,
            "count": 1,
            "per_page": "20",
            "current_page": 1,
            "total_pages": 1,
            "links": {
                "next_page": null,
                "previous_page": null
            }
        }
    },
    "data": [
        {
            "id": 1,
            "component_id": 0,
            "name": "Incident Name",
            "status": 4,
            "visible": 1,
            "message": "Incident Message",
            "scheduled_at": "2015-08-01 12:00:00",
            "created_at": "2015-08-01 12:00:00",
            "updated_at": "2015-08-01 12:00:00",
            "deleted_at": null,
            "human_status": "Fixed"
        }
    ]
}
 

Searchable Keys

Advanced API Usage

Please refer to the Advanced API Usage guide.

  • id
  • component_Id
  • name
  • status
  • visible
Suggest Edits

/incidents/:incident

Get an Incident.

 
gethttps://demo.cachethq.io/api/v1/incidents/incident
curl --request GET \
  --url https://demo.cachethq.io/api/v1/incidents/incident
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/incidents/incident' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/incidents/incident")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/incidents/incident");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/incidents/incident"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "component_id": 0,
        "name": "Incident Name",
        "status": 4,
        "visible": 1,
        "message": "Incident Message",
        "scheduled_at": "2015-08-01 12:00:00",
        "created_at": "2015-08-01 12:00:00",
        "updated_at": "2015-08-01 12:00:00",
        "deleted_at": null,
        "human_status": "Fixed"
    }
}

Path Params

incident
int32
required

Incident ID

 
Suggest Edits

/incidents

Create a new Incident.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1/incidents
curl --request POST \
  --url https://demo.cachethq.io/api/v1/incidents
var request = require("request");

var options = { method: 'POST',
  url: 'https://demo.cachethq.io/api/v1/incidents' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/incidents")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1/incidents");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/incidents"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "component_id": 0,
        "name": "Incident Name",
        "status": 4,
        "visible": 1,
        "message": "Incident Message",
        "scheduled_at": "2015-08-01 12:00:00",
        "created_at": "2015-08-01 12:00:00",
        "updated_at": "2015-08-01 12:00:00",
        "deleted_at": null,
        "human_status": "Fixed"
    }
}

Body Params

name
string
required

Name of the incident

message
string
required

A message (supporting Markdown) to explain more

status
int32
required

Status of the incident

visible
int32
required

Whether the incident is publicly visible

component_id
int32

Component to update. (Required with component_status)

component_status
int32

The status to update the given component with

notify
boolean

Whether to notify subscribers

created_at
date

When the incident was created

template
string

The template slug to use.

vars
array of strings

The variables to pass to the template.

 

The component_status field can be one of values found in the Component Statuses page.

Suggest Edits

/incidents/:incident

Update an Incident.

 

Header Auth

 Authentication is required for this endpoint.
puthttps://demo.cachethq.io/api/v1/incidents/incident
curl --request PUT \
  --url https://demo.cachethq.io/api/v1/incidents/incident
var request = require("request");

var options = { method: 'PUT',
  url: 'https://demo.cachethq.io/api/v1/incidents/incident' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/incidents/incident")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://demo.cachethq.io/api/v1/incidents/incident");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/incidents/incident"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "component_id": 0,
        "name": "Incident Name",
        "status": 4,
        "visible": 1,
        "message": "Incident Message",
        "scheduled_at": "2015-08-01 12:00:00",
        "created_at": "2015-08-01 12:00:00",
        "updated_at": "2015-08-01 12:00:00",
        "deleted_at": null,
        "human_status": "Fixed"
    }
}

Path Params

incident
int32
required

Incident ID.

Body Params

name
string

Name of the incident

message
string

A message (supporting Markdown) to explain more

status
int32

Status of the incident

visible
int32

Whether the incident is publicly visible

component_id
int32

Component to update. (Required for component_status)

component_status
int32

The status to update the given component with

notify
boolean

Whether to notify subscribers

 
Suggest Edits

/incidents/:incident

Delete an Incident.

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://demo.cachethq.io/api/v1/incidents/incident
curl --request DELETE \
  --url https://demo.cachethq.io/api/v1/incidents/incident
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://demo.cachethq.io/api/v1/incidents/incident' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/incidents/incident")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://demo.cachethq.io/api/v1/incidents/incident");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/incidents/incident"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

incident
int32
required

Incident ID

 
Suggest Edits

/incidents/:incident/updates

Get all Incident Updates for an Incident.

 

Header Auth

 Authentication is required for this endpoint.
gethttps://demo.cachethq.io/api/v1/incidents/incident/updates
curl --request GET \
  --url https://demo.cachethq.io/api/v1/incidents/incident/updates
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/incidents/incident/updates' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/incidents/incident/updates")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/incidents/incident/updates");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/incidents/incident/updates"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "meta":{
        "pagination":{
            "total":4,
            "count":4,
            "per_page":20,
            "current_page":1,
            "total_pages":1,
            "links":{
                "next_page":null,
                "previous_page":null
            }
        }
    },
    "data":[
        {
            "id":1,
            "incident_id":1,
            "status":4,
            "message":"The monkeys are back and rested!",
            "user_id":1,
            "created_at":"2016-12-05 19:37:20",
            "updated_at":"2016-12-05 19:37:20",
            "human_status":"Fixed",
            "permalink":"http://cachet.app/incidents/1#update-1"
        },
        {
            "id":2,
            "incident_id":1,
            "status":3,
            "message":"Our monkeys need a break from performing. They'll be back after a good rest.",
            "user_id":1,
            "created_at":"2016-12-05 19:37:20",
            "updated_at":"2016-12-05 19:37:20",
            "human_status":"Watching",
            "permalink":"http://cachet.app/incidents/1#update-2"
        },
        {
            "id":3,
            "incident_id":1,
            "status":2,
            "message":"We have identified the issue with our lovely performing monkeys.",
            "user_id":1,
            "created_at":"2016-12-05 19:37:20",
            "updated_at":"2016-12-05 19:37:20",
            "human_status":"Identified",
            "permalink":"http://cachet.app/incidents/1#update-3"
        },
        {
            "id":4,
            "incident_id":2,
            "status":3,
            "message":"We're actively watching this issue, so it remains unresolved.",
            "user_id":1,
            "created_at":"2016-12-05 19:37:20",
            "updated_at":"2016-12-05 19:37:20",
            "human_status":"Watching",
            "permalink":"http://cachet.app/incidents/2#update-4"
        }
    ]
}

Path Params

incident
int32
required

Incident ID

 
Suggest Edits

/incidents/:incident/updates/:update

Get an Incident Update.

 

Header Auth

 Authentication is required for this endpoint.
gethttps://demo.cachethq.io/api/v1/incidents/incident/updates/:iupdate
curl --request GET \
  --url https://demo.cachethq.io/api/v1/incidents/incident/updates/:iupdate
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/incidents/incident/updates/:iupdate' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/incidents/incident/updates/:iupdate")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/incidents/incident/updates/:iupdate");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/incidents/incident/updates/:iupdate"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

incident
int32
required

Incident ID

update
int32
required

Incident Update ID

 
Suggest Edits

/metrics

Get all Metrics,

 
gethttps://demo.cachethq.io/api/v1/metrics
curl --request GET \
  --url https://demo.cachethq.io/api/v1/metrics
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/metrics' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/metrics")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/metrics");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/metrics"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "meta": {
        "pagination": {
            "total": 1,
            "count": 1,
            "per_page": "20",
            "current_page": 1,
            "total_pages": 1,
            "links": {
                "next_page": null,
                "previous_page": null
            }
        }
    },
    "data": [
        {
            "id": 1,
            "name": "Coffee",
            "suffix": "Cups",
            "description": "Cups of coffee consumed.",
            "default_value": "0.000",
            "calc_type": 1,
            "display_chart": 1,
            "created_at": "2015-08-01 12:00:00",
            "updated_at": "2015-08-01 12:00:00",
            "default_view_name": "Last 12 Hours"
        }
    ]
}
 
Suggest Edits

/metrics

Create a new Metric.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1/metrics
curl --request POST \
  --url https://demo.cachethq.io/api/v1/metrics
var request = require("request");

var options = { method: 'POST',
  url: 'https://demo.cachethq.io/api/v1/metrics' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/metrics")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1/metrics");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/metrics"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
    "name":"Visitors",
    "description":"How many visitors",
    "suffix":"Visitors per hour",
    "default_value":"0",
    "display_chart":"1"
}

Body Params

name
string
required

Name of metric

suffix
string
required

Measurments in

description
string
required

Description of what the metric is measuring

default_value
int32
required

The default value to use when a point is added

display_chart
int32

Whether to display the chart on the status page

 
Suggest Edits

/metrics/:metric

Get a Metric.

 
gethttps://demo.cachethq.io/api/v1/metrics/metric
curl --request GET \
  --url https://demo.cachethq.io/api/v1/metrics/metric
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/metrics/metric' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/metrics/metric")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/metrics/metric");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/metrics/metric"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "name": "Coffee",
        "suffix": "Cups",
        "description": "Cups of coffee consumed.",
        "default_value": "0.000",
        "calc_type": 1,
        "display_chart": 1,
        "created_at": "2015-08-01 12:00:00",
        "updated_at": "2015-08-01 12:00:00",
        "default_view_name": "Last 12 Hours"
    }
}

Path Params

metric
int32
required

Metric ID

 
Suggest Edits

/metrics/:metric

Delete a Metric.

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://demo.cachethq.io/api/v1/metrics/metric
curl --request DELETE \
  --url https://demo.cachethq.io/api/v1/metrics/metric
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://demo.cachethq.io/api/v1/metrics/metric' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/metrics/metric")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://demo.cachethq.io/api/v1/metrics/metric");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/metrics/metric"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

metric
int32
required

Metric ID

 
Suggest Edits

/metrics/:metric/points

Get Points for a Metric.

 
gethttps://demo.cachethq.io/api/v1/metrics/metric/points
curl --request GET \
  --url https://demo.cachethq.io/api/v1/metrics/metric/points
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/metrics/metric/points' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/metrics/metric/points")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/metrics/metric/points");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/metrics/metric/points"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "data": [
        {
            "id": 1,
            "metric_id": 1,
            "value": 1,
            "created_at": "2015-03-11 14:21:44",
            "updated_at": "2015-03-11 14:21:44"
        },
        {
            "id": 2,
            "metric_id": 1,
            "value": 3,
            "created_at": "2015-03-11 14:22:11",
            "updated_at": "2015-03-11 14:22:11"
        },
        {
            "id": 3,
            "metric_id": 1,
            "value": 3,
            "created_at": "2015-03-11 14:34:55",
            "updated_at": "2015-03-11 14:34:55"
        }
    ]
}

Path Params

metric
int32
required

Metric ID

 
Suggest Edits

/metrics/:metric/points

Add a Metric Point to a Metric.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1/metrics/metric/points
curl --request POST \
  --url https://demo.cachethq.io/api/v1/metrics/metric/points
var request = require("request");

var options = { method: 'POST',
  url: 'https://demo.cachethq.io/api/v1/metrics/metric/points' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/metrics/metric/points")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1/metrics/metric/points");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/metrics/metric/points"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
    "data": [
        {
            "id": 1,
            "metric_id": 1,
            "value": 1,
            "created_at": "2015-03-11 14:21:44",
            "updated_at": "2015-03-11 14:21:44"
        },
        {
            "id": 2,
            "metric_id": 1,
            "value": 3,
            "created_at": "2015-03-11 14:22:11",
            "updated_at": "2015-03-11 14:22:11"
        },
        {
            "id": 3,
            "metric_id": 1,
            "value": 3,
            "created_at": "2015-03-11 14:34:55",
            "updated_at": "2015-03-11 14:34:55"
        }
    ]
}

Path Params

metric
int32
required

Metric ID

Body Params

value
double
required

Value to plot on the metric graph

timestamp
string

Unix timestamp of the point was measured

 
Suggest Edits

/metrics/:metric/points/:point

Delete a Metric Point.

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://demo.cachethq.io/api/v1/metrics/metric/points/point
curl --request DELETE \
  --url https://demo.cachethq.io/api/v1/metrics/metric/points/point
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://demo.cachethq.io/api/v1/metrics/metric/points/point' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/metrics/metric/points/point")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://demo.cachethq.io/api/v1/metrics/metric/points/point");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/metrics/metric/points/point"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

metric
int32
required

Metric ID

point
int32
required

Metric Point ID

 
Suggest Edits

/subscribers

Returns all subscribers.

 

Header Auth

 Authentication is required for this endpoint.
gethttps://demo.cachethq.io/api/v1/subscribers
curl --request GET \
  --url https://demo.cachethq.io/api/v1/subscribers
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/subscribers' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/subscribers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/subscribers");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/subscribers"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
   "meta": {
        "pagination": {
            "total": 1,
            "count": 1,
            "per_page": "20",
            "current_page": 1,
            "total_pages": 1,
            "links": {
                "next_page": null,
                "previous_page": null
            }
        }
    },
    "data": {
        "id": 1,
        "email": "support@alt-three.com",
        "verify_code": "1234567890",
        "verified_at": "2015-07-24 14:42:24",
        "created_at": "2015-07-24 14:42:24",
        "updated_at": "2015-07-24 14:42:24"
    }
}
 
Suggest Edits

/subscribers

Create a new subscriber.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1/subscribers
curl --request POST \
  --url https://demo.cachethq.io/api/v1/subscribers
var request = require("request");

var options = { method: 'POST',
  url: 'https://demo.cachethq.io/api/v1/subscribers' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/subscribers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1/subscribers");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/subscribers"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
    "data": {
        "id": 1,
        "email": "support@alt-three.com",
        "verify_code": "1234567890",
        "verified_at": "2015-07-24 14:42:24",
        "created_at": "2015-07-24 14:42:24",
        "updated_at": "2015-07-24 14:42:24"
    }
}

Body Params

email
string
required

Email address to subscribe

verify
boolean

Whether to send verification email

components
array of integers

If not provided, you'll subscribe to all components.

 
Suggest Edits

/subscribers/:subscriber

Delete a Subscriber.

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://demo.cachethq.io/api/v1/subscribers/subscriber
curl --request DELETE \
  --url https://demo.cachethq.io/api/v1/subscribers/subscriber
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://demo.cachethq.io/api/v1/subscribers/subscriber' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/subscribers/subscriber")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://demo.cachethq.io/api/v1/subscribers/subscriber");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/subscribers/subscriber"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

subscriber
int32
required

Subscriber ID

 
Suggest Edits

Introduction

An introduction into Time Sensitive Actions.

 

Task Scheduler

It's important that the Configuring the Queue is running before the immediate setup of a Time Sensitive Action.

Semi-Immutable Actions

Actions are semi-immutable in that only a select few fields can be updated:

  • Name
  • Description
  • Active
  • Visible
  • Group ID

If you need to change the frequency, latency or timezone then you should create a new Time Sensitive Action.

Suggest Edits

/actions

Returns all time sensitive actions.

 

Header Auth

 Authentication is required for this endpoint.
gethttps://demo.cachethq.io/api/v1/actions
curl --request GET \
  --url https://demo.cachethq.io/api/v1/actions
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/actions' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/actions")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/actions");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/actions"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "meta":{
        "pagination":{
            "total":1,
            "count":1,
            "per_page":20,
            "current_page":1,
            "total_pages":1,
            "links":{
                "next_page":null,
                "previous_page":null
            }
        }
    },
    "data":[
        {
            "id":1,
            "name":"Yesterday's Sales",
            "timed_action_group_id":0,
            "description":"Send daily KPI's to the big boss!",
            "active":true,
          	"start_at": "2016-09-01 00:00:00",
            "timezone":"Europe/London",
            "window_length":86400,
            "completion_latency":10800,
            "created_at":"2016-08-31 13:00:00",
            "updated_at":"2016-08-31 13:00:00",
            "deleted_at":null,
            "timezone_offset": 60,
            "group_name":null
        }
    ]
}
 

Time Sensitive Actions are available from v2.4 onwards!

Suggest Edits

/actions

Create a new action.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1
curl --request POST \
  --url https://demo.cachethq.io/api/v1
var request = require("request");

var options = { method: 'POST', url: 'https://demo.cachethq.io/api/v1' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
    "data":{
        "id":1,
        "name":"Yesterday's Sales",
        "timed_action_group_id":0,
        "description":"Send daily KPI's to the big boss!",
        "active":true,
        "start_at": "2016-09-01 00:00:00",
        "timezone":"Europe/London",
        "window_length":86400,
        "completion_latency":10800,
        "created_at":"2016-08-31 13:00:00",
        "updated_at":"2016-08-31 13:00:00",
        "deleted_at":null,
        "timezone_offset": 60,
        "group_name":null
    }
}

Body Params

name
string
required

The name of the action.

description
string

A description of what the action does.

active
boolean

Whether the action is active.

start_at
date
required
timezone
string
required

The timezone this action runs in.

window_length
int32
required

The number of seconds between each instance running.

completion_latency
int32
required

The number of seconds this job has to complete.

timed_action_group_id
int32

The group id to put the action under.

 
Suggest Edits

/actions/:action

Get an Action.

 

Header Auth

 Authentication is required for this endpoint.
gethttps://demo.cachethq.io/api/v1/actions/action
curl --request GET \
  --url https://demo.cachethq.io/api/v1/actions/action
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/actions/action' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/actions/action")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/actions/action");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/actions/action"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
    "data":{
        "id":1,
        "name":"Yesterday's Sales",
        "timed_action_group_id":0,
        "description":"Send daily KPI's to the big boss!",
        "active":true,
        "start_at": "2016-09-01 00:00:00",
        "timezone":"Europe/London",
        "window_length":86400,
        "completion_latency":10800,
        "created_at":"2016-08-31 13:00:00",
        "updated_at":"2016-08-31 13:00:00",
        "deleted_at":null,
        "timezone_offset": 60,
        "group_name":null
    }
}

Path Params

action
int32
required

Action ID

 
Suggest Edits

/actions/:action

Delete an Action.

 

Header Auth

 Authentication is required for this endpoint.
deletehttps://demo.cachethq.io/api/v1/actions/action
curl --request DELETE \
  --url https://demo.cachethq.io/api/v1/actions/action
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://demo.cachethq.io/api/v1/actions/action' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/actions/action")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://demo.cachethq.io/api/v1/actions/action");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/actions/action"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned
Try the API to see results

Path Params

action
int32
required

Action ID

 
Suggest Edits

/actions/:action

Update an Action.

 

Header Auth

 Authentication is required for this endpoint.
puthttps://demo.cachethq.io/api/v1/actions/action
curl --request PUT \
  --url https://demo.cachethq.io/api/v1/actions/action
var request = require("request");

var options = { method: 'PUT',
  url: 'https://demo.cachethq.io/api/v1/actions/action' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/actions/action")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://demo.cachethq.io/api/v1/actions/action");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/actions/action"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned
{
  "data": {
    "id": 1,
    "name": "Daily KPI's",
    "timed_action_group_id": 0,
    "description": "Send KPI's to the big bosses!",
    "active": true,
    "visible": true,
    "start_at": "2016-09-05 00:00:00",
    "timezone": "Europe/London",
    "schedule_interval": 86400,
    "completion_latency": 10800,
    "created_at": "2016-09-04 15:51:23",
    "updated_at": "2016-09-11 15:08:13",
    "deleted_at": null,
    "timezone_offset": 60,
    "group_name": null
  }
}

Path Params

action
int32
required

Action ID

Body Params

name
string

The name to update the action to.

description
string

The description to update the action to.

active
boolean

The active state to update the action to.

timed_action_group_id
int32

The group id to update the action to.

 
Suggest Edits

/actions/:action/instances

Get all Action instances.

 

Header Auth

 Authentication is required for this endpoint.
gethttps://demo.cachethq.io/api/v1/actions/action/instances
curl --request GET \
  --url https://demo.cachethq.io/api/v1/actions/action/instances
var request = require("request");

var options = { method: 'GET',
  url: 'https://demo.cachethq.io/api/v1/actions/action/instances' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/actions/action/instances")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://demo.cachethq.io/api/v1/actions/action/instances");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/actions/action/instances"

response = requests.request("GET", url)

print(response.text)
A binary file was returned
{
  "meta": {
    "pagination": {
      "total": 25,
      "count": 20,
      "per_page": 20,
      "current_page": 1,
      "total_pages": 2,
      "links": {
        "next_page": "https://demo.cachethq.io/api/v1/actions/1/instances?page=2",
        "previous_page": null
      }
    }
  },
  "data": [
    {
      "id": 25,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-12 00:00:00",
      "completed_at": {
        "date": "2016-09-12 03:01:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-13 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-13 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 24,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-11 00:00:00",
      "completed_at": {
        "date": "2016-09-11 08:34:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-12 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-12 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 23,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-10 00:00:00",
      "completed_at": {
        "date": "2016-09-10 11:45:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-11 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-11 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 22,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-09 00:00:00",
      "completed_at": {
        "date": "2016-09-12 20:59:41.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-10 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-10 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 21,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-08 00:00:00",
      "completed_at": {
        "date": "2016-09-08 04:10:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-09 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-09 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 20,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-07 00:00:00",
      "completed_at": {
        "date": "2016-09-07 04:10:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-08 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-08 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 19,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-06 00:00:00",
      "completed_at": {
        "date": "2016-09-12 20:59:41.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-07 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-07 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 18,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-05 00:00:00",
      "completed_at": {
        "date": "2016-09-05 10:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:03",
      "updated_at": "2016-09-04 16:59:03",
      "ended_at": {
        "date": "2016-09-06 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-06 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 17,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-04 00:00:00",
      "completed_at": {
        "date": "2016-09-04 09:20:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-09-05 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-05 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 16,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-03 00:00:00",
      "completed_at": {
        "date": "2016-09-03 10:20:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-09-04 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-04 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 15,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-02 00:00:00",
      "completed_at": {
        "date": "2016-09-02 10:20:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-09-03 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-03 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 14,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-09-01 00:00:00",
      "completed_at": {
        "date": "2016-09-01 06:23:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-09-02 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-02 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 13,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-31 00:00:00",
      "completed_at": {
        "date": "2016-08-31 05:50:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-09-01 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-09-01 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 12,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-30 00:00:00",
      "completed_at": {
        "date": "2016-08-30 04:20:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-08-31 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-08-31 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 11,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-29 00:00:00",
      "completed_at": {
        "date": "2016-08-29 08:20:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-08-30 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-08-30 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 10,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-28 00:00:00",
      "completed_at": {
        "date": "2016-08-28 10:30:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-08-29 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-08-29 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 9,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-27 00:00:00",
      "completed_at": {
        "date": "2016-08-27 04:45:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-08-28 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-08-28 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 8,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-26 00:00:00",
      "completed_at": {
        "date": "2016-08-26 10:15:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-08-27 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-08-27 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 7,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-25 00:00:00",
      "completed_at": {
        "date": "2016-08-25 04:20:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-08-26 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-08-26 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    },
    {
      "id": 6,
      "timed_action_id": 1,
      "message": null,
      "started_at": "2016-08-24 00:00:00",
      "completed_at": {
        "date": "2016-08-24 10:10:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "created_at": "2016-09-04 16:59:02",
      "updated_at": "2016-09-04 16:59:02",
      "ended_at": {
        "date": "2016-08-25 01:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      },
      "target_completed_at": {
        "date": "2016-08-25 02:00:00.000000",
        "timezone_type": 3,
        "timezone": "Europe/London"
      }
    }
  ]
}

Path Params

action
int32
required

Action ID

 
Suggest Edits

/actions/:action/instances

Create a new Action.

 

Header Auth

 Authentication is required for this endpoint.
posthttps://demo.cachethq.io/api/v1/actions/action/instances
curl --request POST \
  --url https://demo.cachethq.io/api/v1/actions/action/instances
var request = require("request");

var options = { method: 'POST',
  url: 'https://demo.cachethq.io/api/v1/actions/action/instances' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://demo.cachethq.io/api/v1/actions/action/instances")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://demo.cachethq.io/api/v1/actions/action/instances");

xhr.send(data);
import requests

url = "https://demo.cachethq.io/api/v1/actions/action/instances"

response = requests.request("POST", url)

print(response.text)
A binary file was returned
{
  	"data": {
        "id": 25,
        "timed_action_id": 1,
        "message": null,
        "started_at": "2016-09-12 00:00:00",
        "completed_at": {
            "date": "2016-09-12 03:01:00.000000",
            "timezone_type": 3,
            "timezone": "Europe/London"
        }
    }
}

Path Params

action
int32
required

Action ID.

Body Params

message
string

An optional message to add to the instance.

started_at
date
required

The time in which the action instance was started.

completed_at
date
required

The time of which the action instance was completed.