API Documentation
Pulses ¶
GET /api/v2/pulses
Requests
GET /api/v2/pulses
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": [
{
"id": "1",
"type": "pulses",
"attributes": {
"deactivated_at": null,
"document_format_id": 1,
"export_params": {},
"repeat_schedule_id": 1,
"schedule_day_id": null,
"schedule_frame_id": null,
"schedule_hour": 9,
"skip_if_empty": true,
"slack_channel": null,
"type_id": 1
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "978"
}
},
"creator": {
"meta": {
"included": false
}
},
"filter": {
"meta": {
"included": false
}
}
}
},
{
"id": "2",
"type": "pulses",
"attributes": {
"deactivated_at": null,
"document_format_id": 1,
"export_params": {},
"repeat_schedule_id": 1,
"schedule_day_id": null,
"schedule_frame_id": null,
"schedule_hour": 9,
"skip_if_empty": true,
"slack_channel": null,
"type_id": 1
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "978"
}
},
"creator": {
"meta": {
"included": false
}
},
"filter": {
"meta": {
"included": false
}
}
}
},
{
"id": "3",
"type": "pulses",
"attributes": {
"deactivated_at": null,
"document_format_id": 1,
"export_params": {},
"repeat_schedule_id": 1,
"schedule_day_id": null,
"schedule_frame_id": null,
"schedule_hour": 9,
"skip_if_empty": true,
"slack_channel": null,
"type_id": 1
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "978"
}
},
"creator": {
"meta": {
"included": false
}
},
"filter": {
"meta": {
"included": false
}
}
}
}
],
"links": {
"first": "http://api-test.productive.io/api/v2/pulses?page%5Bnumber%5D=1&page%5Bsize%5D=30",
"last": "http://api-test.productive.io/api/v2/pulses?page%5Bnumber%5D=1&page%5Bsize%5D=30"
},
"meta": {
"current_page": 1,
"total_pages": 1,
"total_count": 3,
"page_size": 30,
"max_page_size": 200
}
}
Get pulsesGET/api/v2/pulses
GET /api/v2/pulses/1
Requests
GET /api/v2/pulses/4
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "4",
"type": "pulses",
"attributes": {
"deactivated_at": null,
"document_format_id": 1,
"export_params": {},
"repeat_schedule_id": 1,
"schedule_day_id": null,
"schedule_frame_id": null,
"schedule_hour": 9,
"skip_if_empty": true,
"slack_channel": null,
"type_id": 1
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "979"
}
},
"creator": {
"meta": {
"included": false
}
},
"filter": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}
POST /api/v2/pulses
Requests
POST /api/v2/pulses
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "pulses",
"attributes": {
"id": null,
"account_id": 980,
"filter_id": 42,
"created_at": null,
"updated_at": null,
"deleted_at": null,
"skip_if_empty": true,
"repeat_schedule_id": 1,
"schedule_hour": 9,
"schedule_day_id": null,
"schedule_frame_id": null,
"creator_id": 3412,
"updater_id": null,
"export_params": {},
"document_format_id": 1,
"type_id": 1,
"slack_channel": null,
"test_pulse": false,
"deactivated_at": null,
"last_scheduled_at": null
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "5",
"type": "pulses",
"attributes": {
"deactivated_at": null,
"document_format_id": 1,
"export_params": {},
"repeat_schedule_id": 1,
"schedule_day_id": null,
"schedule_frame_id": null,
"schedule_hour": 9,
"skip_if_empty": true,
"slack_channel": null,
"type_id": 1
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "980"
}
},
"creator": {
"meta": {
"included": false
}
},
"filter": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}
POST /api/v2/pulses
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "pulses",
"attributes": {
"id": null,
"account_id": 989,
"filter_id": 0,
"created_at": null,
"updated_at": null,
"deleted_at": null,
"skip_if_empty": true,
"repeat_schedule_id": 1,
"schedule_hour": 9,
"schedule_day_id": null,
"schedule_frame_id": null,
"creator_id": 3430,
"updater_id": null,
"export_params": {},
"document_format_id": 1,
"type_id": 1,
"slack_channel": null,
"test_pulse": false,
"deactivated_at": null,
"last_scheduled_at": null
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "attribute is invalid",
"source": {
"pointer": "data/attributes/filter"
}
}
]
}
POST /api/v2/pulses/test
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "pulses",
"attributes": {
"id": null,
"account_id": 993,
"filter_id": 54,
"created_at": null,
"updated_at": null,
"deleted_at": null,
"skip_if_empty": true,
"repeat_schedule_id": 1,
"schedule_hour": 9,
"schedule_day_id": null,
"schedule_frame_id": null,
"creator_id": 3443,
"updater_id": null,
"export_params": {},
"document_format_id": 1,
"type_id": 1,
"slack_channel": null,
"test_pulse": false,
"deactivated_at": null,
"last_scheduled_at": null
}
}
}
Responses
This response has no content.
POST /api/v2/pulses/test
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "pulses",
"attributes": {
"id": null,
"account_id": 994,
"filter_id": 55,
"created_at": null,
"updated_at": null,
"deleted_at": null,
"skip_if_empty": true,
"repeat_schedule_id": 1,
"schedule_hour": 9,
"schedule_day_id": null,
"schedule_frame_id": null,
"creator_id": 3445,
"updater_id": null,
"export_params": {},
"document_format_id": 1,
"type_id": 1,
"slack_channel": null,
"test_pulse": false,
"deactivated_at": null,
"last_scheduled_at": null
}
}
}
Responses
This response has no content.
POST /api/v2/pulses/test
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "pulses",
"attributes": {
"id": null,
"account_id": 995,
"filter_id": 56,
"created_at": null,
"updated_at": null,
"deleted_at": null,
"skip_if_empty": true,
"repeat_schedule_id": null,
"schedule_hour": 9,
"schedule_day_id": null,
"schedule_frame_id": null,
"creator_id": 3448,
"updater_id": null,
"export_params": {},
"document_format_id": 1,
"type_id": 1,
"slack_channel": null,
"test_pulse": false,
"deactivated_at": null,
"last_scheduled_at": null
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/repeat_schedule_id"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "is not included in the list",
"source": {
"pointer": "data/attributes/repeat_schedule_id"
}
}
]
}
Creates a pulsePOST/api/v2/pulses
URI Parameters
- filter_id
number
(required) Example: 1filter id
- skip_if_empty
boolean
(required) Example: trueif set to true, pulse won’t be sent when there is no data in the report
- repeat_schedule_id
number
(required) Example: 1how often is the pulse sent (1: daily, 2: weekly, 3: monthly)
- schedule_hour
number
(required) Example: 9time the pulse is sent (0-23)
- schedule_day_id
number
(required) Example: 1day in week when the pulse is sent (1: monday, …, 7: sunday)
- schedule_frame_id
number
(required) Example: 1when pulse is sent monthly, frame determins if sent on first(id: 1)/last(id: 2) schedule_day of the month, or in the middle(id: 3) of the month (15th)
PATCH /api/v2/pulses/1
Requests
PATCH /api/v2/pulses/9
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "pulses",
"attributes": {
"schedule_hour": 15
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "9",
"type": "pulses",
"attributes": {
"deactivated_at": null,
"document_format_id": 1,
"export_params": {},
"repeat_schedule_id": 1,
"schedule_day_id": null,
"schedule_frame_id": null,
"schedule_hour": 15,
"skip_if_empty": true,
"slack_channel": null,
"type_id": 1
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "991"
}
},
"creator": {
"meta": {
"included": false
}
},
"filter": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}
PATCH /api/v2/pulses/10
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "pulses",
"attributes": {
"schedule_hour": null
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/schedule_hour"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "is not included in the list",
"source": {
"pointer": "data/attributes/schedule_hour"
}
}
]
}
DELETE /api/v2/pulses/1
Requests
DELETE /api/v2/pulses/13
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
This response has no content.
Generated by aglio on 19 Apr 2024