Monitor

GET /user/:user_code/monitor

Read Monitor group list

Detail

Request

No Parameters

Response

Key

Type

Value

results

Array

Monitor group list

id int

ID of the Monitor group. For groups where the ID is null, record unassigned service adaptors in the Monitor group

name String

Monitor group name

member int

Number of service adaptors assigned to the Monitor group

Sample

Request

URL
GET https://*.sacm.jp/public-api/v1/user/tsa99990001/monitor

Response

Body
{
  "results": [
    {
      "id": null,
      "name": null,
      "member": 3
    },
    {
      "id": 1535,
      "name":" Monitor1",
      "member": 2
    }
  ]
}

POST /user/:user_code/monitor

Add Monitor group

Detail

Request

Header
Content-Type: application/json
Body

Key

Type

Value

name

String

Monitor group name (1 - 40 characters) (required)

Response

Status Code
201
Body

Key

Type

Value

id

int

ID of the Monitor group

name

String

Monitor group name

reports

Array

Reporting mail address list

sa

Array

Assigned service adaptor list

Sample

Request

URL
POST https://*.sacm.jp/public-api/v1/user/tsa99990001/monitor
Header
Content-Type: application/json
Body
{
  "name": "Monitor1"
}

Response

Header
Content-Type: application/json
Body
{
  "id": 1,
  "name": "Monitor1",
  "reports": [
    null,
    null,
    null,
    null,
    null
  ],
  "sa": [
  ]
}

Description

Up to 5 Monitor groups can be added

GET /user/:user_code/monitor/:id

Read Monitor group details

Detail

Request

No Parameters

Response

Body

Key

Type

Value

id

int

ID of the Monitor group

name

String

Monitor group name

reports

Array

Reporting mail address list

sa

Array

Assigned service adaptor list

Sample

Request

URL
GET https://*.sacm.jp/public-api/v1/user/tsa99990001/monitor/1

Response

Header
Content-Type: application/json
Body
{
  "id": 1,
  "name": "Monitor1",
  "reports": [
    sample@example.com,
    sample@example.co.jp,
    null,
    null,
    null
  ],
  "sa": [
    {
      "code": "tss99990001",
      "name": "Service adapter 001",
      "description": "MEMO",
      "distributionId": "0001-0000-0101-0000-0000-0000-1234-5678",
      "up": true,
      "configState": "pushready",
      "group": {
        "id": 1,
        "name": "Folder1"
      },
      "template": {
        "id": 1,
        "name": "Template1"
      },
      "monitor": {
        "id": 1,
        "name": "Monitor1"
      },
      "date": {
        "lastPushReady": "2012/06/05 16:00:09",
        "lastHeartbeatReport": "2012/05/11 17:10:02",
        "lastPulled": "2012/05/11 17:06:22",
        "firstPulled": "2012/04/11 17:07:00"
      },
      "type": 0,
      "mode": null
    }
  ]
}

PUT /user/:user_code/monitor/:id

Update Monitor group details

Detail

Request

Header
Content-Type: application/json
Body

Key

Type

Value

name

String

Monitor group name (1 - 40 characters) (option)

reports

Array

Reporting mail address list (must be 5 each) (option)

address String

Reporting mail address

sa

Array

List of assigned service adaptors (option)

code String

SA code

Response

Body

Key

Type

Value

id

int

ID of the Monitor group

name

String

Monitor group name

reports

Array

Reporting mail address list

address String

Reporting mail address

sa

Array

Assigned service adaptor list

Sample

Request

URL
PUT https://*.sacm.jp/public-api/v1/user/tsa99990001/monitor/1
Header
Content-Type: application/json
Body
{
  "name": "Monitor2",
  "reports": [
    {
      "address": "sample@example.com"
    },
    {
      "address": "sample@example.co.jp"
    },
    null,
    null,
    null
  ],
  "sa": [
    {
      "code": "tss99990001"
    },
    {
      "code": "tss99990002"
    }
  ]
}

Response

Header
Content-Type: application/json
Body
{
  "id": 1,
  "name": "Monitor1",
  "reports": [
    {
      "address": "sample@example.com"
    },
    {
      "address": "sample@example.co.jp"
    },
    null,
    null,
    null
  ],
  "sa": [
    {
      "code": "tss99990001",
      "name": "Service adapter 001",
      "description": "MEMO",
      "distributionId": "0001-0000-0101-0000-0000-0000-1234-5678",
      "up": true,
      "configState": "pushready",
      "group": {
        "id": 1,
        "name": "Folder1"
      },
      "template": {
        "id": 1,
        "name": "Template1"
      },
      "monitor": {
        "id": 1,
        "name": "Monitor2"
      },
      "date": {
        "lastPushReady": "2012/06/05 16:00:09",
        "lastHeartbeatReport": "2012/05/11 17:10:02",
        "lastPulled": "2012/05/11 17:06:22",
        "firstPulled": "2012/04/11 17:07:00"
      },
      "type": 0,
      "mode": null
    },
    {
      "code": "tss99990002",
      "name": "Service adapter 002",
      "description": "MEMO",
      "distributionId": "0001-0000-0101-0000-0000-0000-5678-1234",
      "up": true,
      "configState": "pushready",
      "group": {
        "id": 2,
        "name": "Folder2"
      },
      "template": {
        "id": 2,
        "name": "Template2"
      },
      "monitor": {
        "id": 1,
        "name": "Monitor2"
      },
      "date": {
        "lastPushReady": "2012/06/05 16:00:09",
        "lastHeartbeatReport": "2012/05/11 17:10:02",
        "lastPulled": "2012/05/11 17:06:22",
        "firstPulled": "2012/04/11 17:07:00"
      },
      "type": 0,
      "mode": null
    }
  ]
}

DELETE /user/:user_code/monitor/:id

Delete Monitor group

Detail

Request

No Parameters

Response

Status Code
204
Header
Content-Type: text/plain
Body

No Body

Sample

Request

URL
DELETE https://*.sacm.jp/public-api/v1/user/tsa99990001/monitor/1

Response

Header
Content-Type: text/plain
Body

No Body