We’ve migrated our documentation to a new site, which means some URLs have changed.
Audience

/persisted/create

Creates a new persisted request. See API authentication for more information about persisted requests.

The user must be authenticated and have feature persistedRequestOwner.

Request

The request object has the following fields:

Name

Type

Required

Description

path

String

Yes

Path to the method to execute when executing the persisted request. This path should also be used as the url resource in the execution request. None of the /widget API calls cannot be used in persisted requests.

request

Object or Array of Object

No

Request object or array of objects sent as parameter when executing the persisted request.

mutable

Object

No

Object with boolean parameters. Fields that have the boolean value true can be modified when executing the persisted request.

description

String

No

Textual description of the persisted request.

Response

The response object has the following fields:

Name

Type

Description

id

String

Identifier for the newly created persisted request.

Examples

Bash
$ python cx.py /persisted/create '{"path":"/site","request":{"siteId":"9222300742735526873"},"description":"Example persisted"}'
{
 "id": "58e5154490191e5ca6b941ee56f6e7349b9d2fe1"
}
$ curl https://api.cxense.com/site?persisted=58e5154490191e5ca6b941ee56f6e7349b9d2fe1
{
 "sites": [
 {
 "id": "9222300742735526873",
 "name": "Example site",
 "url": "https://www.example.com"
 "country": "US",
 "timeZone": "America/Los_Angeles",
 }
 ]
}

Last updated: