Account#

Use the following Account operations to manage user accounts including finding out about resource and rate limits and getting information about write operations, called audits.

The following table describes the Account operations attributes:

Name

Description

Validation

metadata

Arbitrary key/value pairs

  • Optional

  • Hash [String, String between 1 and 255 characters long:String, String between 1 and 255 characters long]

  • Array or object with number of items between 0 and 256

webhook_token

  • Optional

  • String between 10 and 64 characters long

Get account information#

GET /account

Returns information about the specified account.

This operation can be paginated. For information, see Paginated collections.

The following table shows the possible response codes for this operation:

Response Code

Name

Description

200

OK

The request completed.

401

Unauthorized

The system received a request from a user that is not authenticated.

403

Forbidden

The system received a request that the user is not authorized to make.

500

Internal Server Error

An unexpected condition was encountered.

503

Service Unavailable

The system is experiencing heavy load or another system failure.

Request#

The following table shows the header parameters for the request:

Name

Type

Description

X-Auth-Token

String (Required)

A valid authentication token with administrative access. For details, see Get your credentials

Note

This operation does not accept a request body.

Response#

Example Get account information: JSON response

{
    "id": "someId",
    "metadata": {
        "key": "aValue"
    },
    "webhook_token": "token12345"
}

Update properties on an account#

PUT /account

Updates account properties.

Refer to the attributes described in the Accounts attributes table may be updated.

The following table shows the possible response codes for this operation:

Response Code

Name

Description

204

OK

The server has fulfilled the request. Does not return a response body.

400

Bad request

The system received an invalid value in a request.

401

Unauthorized

The system received a request from a user that is not authenticated.

403

Forbidden

The system received a request that the user is not authorized to make.

404

Not Found

The URL, entity, or account requested is not found in the system.

500

Internal Server Error

An unexpected condition was encountered.

503

Service Unavailable

The system is experiencing heavy load or another system failure.

Request#

The following table shows the header parameters for the request:

Name

Type

Description

X-Auth-Token

String (Required)

A valid authentication token with administrative access. For details, see Get your credentials

Example Update account: JSON request

{
    "webhook_token":"test123456"
}

Response#

This operation does not return a response body.

Get Limits#

GET /limits

Returns resource and rate limits that apply to the specified account.

The following table shows the possible response codes for this operation:

Response Code

Name

Description

200

OK

The request completed.

401

Unauthorized

The system received a request from a user that is not authenticated.

403

Forbidden

The system received a request that the user is not authorized to make.

500

Internal Server Error

An unexpected condition was encountered.

503

Service Unavailable

The system is experiencing heavy load or another system failure.

Request#

The following table shows the header parameters for the request:

Name

Type

Description

X-Auth-Token

String (Required)

A valid authentication token with administrative access. For details, see Get your credentials

Note

This operation does not accept a request body.

Response#

Example Get limits: JSON response

{
    "resource": {
        "checks": 150,
        "alarms": 50
    },
    "rate": {
        "global": {
            "limit": 50000,
            "used": 500,
            "window": "24 hours"
        },
        "test_check": {
            "limit": 500,
            "used": 5,
            "window": "24 hours"
        },
        "test_alarm": {
            "limit": 500,
            "used": 2,
            "window": "24 hours"
        }
    }
}

Get audit information#

GET /audits

Returns audit information for the specified account.

Rackspace Monitoring records every write operation in an audit. For more information about how audits are recorded, see Audits.

Audits are accessible as a Time Series Collection. By default the API queries the last 7 days of audit information.

This operation can be paginated. For information, see Paginated collections.

..note:

Rackspace Monitoring currently doesn't have a filtering functionality to
filter for specific items. It is recommended that you write a script to
shrink the long list of audit content.

The following table shows the possible response codes for this operation:

Response Code

Name

Description

200

OK

The request completed.

401

Unauthorized

The system received a request from a user that is not authenticated.

403

Forbidden

The system received a request that the user is not authorized to make.

500

Internal Server Error

An unexpected condition was encountered.

503

Service Unavailable

The system is experiencing heavy load or another system failure.

Request#

The following table shows the header parameters for the request:

Name

Type

Description

X-Auth-Token

String (Required)

A valid authentication token with administrative access. For details, see Get your credentials

Note

This operation does not accept a request body.

Response#

Example Get audit information: JSON response

{
    "values": [
        {
            "id": "84428400-0b26-11e1-9dd4-d7e69257c9a7",
            "headers": {
                "host": "127.0.0.1",
                "user-agent": "ele-client/ae0a53c",
                "accept": "application/xml",
                "content-type": "application/xml",
                "x-auth-token": "917ac3575c29e2f27e7236836a732615d62e416d4aead4d5",
                "content-length": 254,
                "connection": "close"
            },
            "url": "/v1.0/entities", // used to create an entity
            "timestamp": 1435174490595,
            "app": "entities",
            "query": null,
            "txnId": ".rh-nzQM.h-ele.r-Kxysr1TO.c-189.ts-1320879585331.v-ae0a53c",
            "payload": "{\"label\":\"0NwhqrC05xKh22OEYZhcQdwkw\",\"ip_addresses\":{\"default\":\"10.0.0.2\"},\"metadata\":{\"all\":\"kinds\",\"of\":\"stuff\",\"can\":\"go\",\"here\":\"null is not a valid value\"}}", // details for create operation
            "method": "POST", // create operation
            "account_id": "frank",
            "who": null,
            "why": null,
            "statusCode": 201
        },
        {
            "id": "849f22f0-0b26-11e1-9dd4-d7e69257c9a7",
            "headers": {
                "host": "127.0.0.1",
                "user-agent": "ele-client/ae0a53c",
                "accept": "application/xml",
                "content-type": "application/xml",
                "x-auth-token": "917ac3575c29e2f27e7236836a732615d62e416d4aead4d5",
                "content-length": 51,
                "connection": "close"
            },
            "url": "/v1.0/entities/enuAc9qZRB", //the entity to update is enuAc9qZR
            "timestamp": 1435174490595,
            "app": "entities",
            "query": null,
            "txnId": ".rh-nzQM.h-ele.r-lobnFBE4.c-195.ts-1320879585945.v-ae0a53c",
            "payload": "{\"label\":\"testing.example.com\"}", // details of the update operation
            "method": "PUT", //update operation
            "account_id": "frank",
            "who": null,
            "why": null,
            "statusCode": 204
        }
    ],
    "metadata": {
        "count": 2,
        "limit": 50,
        "marker": null,
        "next_marker": null,
        "next_href": null
    }
}