Fetch a program's organization hierarchy
get
/rest/api/v1.3/attributes/programs/{programName}
Fetch a list of organizations that can access a program.
Request
Supported Media Types
- application/json
Path Parameters
-
programName: string
The Program name
Response
Supported Media Types
- application/json
Default Response
Nested Schema : organizations
Type:
Show Source
object-
attributeValues(optional):
array attributeValues
Value of the Assigned Attributes
Nested Schema : attributeValues
Type:
arrayValue of the Assigned Attributes
Show Source
-
Array of:
object assigned attribute
Title:
assigned attribute
Nested Schema : assigned attribute
Type:
objectTitle:
Show Source
assigned attribute-
id(optional):
string
ID of the attribute
-
lineage(optional):
string
Description of the attribute's heirarchy
-
name(optional):
string
Name of the attribute
Examples
This interface is used to retrieve the organizations which have access to a program. To learn more about Organizations in Responsys, see the Responsys Help Center.
A successful request requires the following headers:
| FIELDS | DESCRIPTION |
|---|---|
| Authorization | <AUTH_TOKEN> |
Sample Request URL:
/rest/api/v1.3/attributes/programs/example_program
Sample response: Success
{
"attributes": {
"organizations": {
"attributeValues": [
{
"id": 7,
"name": "USA",
"lineage": "7:"
}
]
}
}
}
Sample Response: Failure
If the program does not exist, the error will resemble the following:
{
"type": "",
"title": "Program not found",
"errorCode": "PROGRAM_NOT_FOUND",
"detail": "Program with the name example_progrm not found",
"errorDetails": []
}