RequestResource ⇐ GenericResource

The RequestResource class provides methods to access the Request
endpoint of the Cloud Blue Connect API.

Kind: global class
Extends: GenericResource
Category: Resources

new RequestResource(client)

Creates a new instance of the RequestResource class.

Returns: RequestResource – An instance of the RequestResource class.

Param Type Description
client ConnectClient An instance of the ConnectClient class.

requestResource.fail(id, reason) ⇒ object

Change the status of a Request to fail.

Kind: instance method of RequestResource
Returns: object – The updated Request object.

Param Type Description
id string The unique identifier of the Request object.
reason string The reason for which the Request has been failed.

requestResource.inquire(id, request) ⇒ object

Change the status of a Request to inquire.
To change the status of the Request to inquire you must provide
either a template id or a template tile.

Kind: instance method of RequestResource
Returns: object – The updated Request object.

Param Type Description
id string The unique identifier of the Request object.
request object The request body.

Example

// request body using a template id
{
  template_id: 'TL-827-840-476'
}

Example

// request body using an activation tile
{
  activation_tile: '<rendered text>'
}

requestResource.approve(id, request) ⇒ object

Change the status of a Request to approved.
To change the status of the Request to approved you must provide
either a template id or a template tile.

Kind: instance method of RequestResource
Returns: object – The updated Request object.

Param Type Description
id string The unique identifier of the Request object.
request object The request body.

Example

// request body using a template id
{
  template_id: 'TL-827-840-476'
}

Example

// request body using an activation tile
{
  activation_tile: '<rendered text>'
}

requestResource.pending(id) ⇒ object

Change the status of a Request to pending.

Kind: instance method of RequestResource
Returns: object – The updated Request object.

Param Type Description
id string The unique identifier of the Request object.
Is this page helpful?
Translate with Google
Copied to clipboard