Fetch all the fields or the primary key fields of the Supplemental Table
get
/rest/api/v1.3/folder/{folderName}/suppData/{suppTableName}
Request
Path Parameters
-
folderName: string
Folder name
-
suppTableName: string
Supplemental Table name
Query Parameters
-
ft(optional): string
**ft=pk** returns only the primary key fields. **ft=all** returns all the fields. By default 'ft' is set to 'all'
Response
Supported Media Types
- application/json
Default Response
Supplemental Data Tables
Root Schema : Supplemental Data Table fields
Type:
object
Title:
Show Source
Supplemental Data Table fields
-
fields(optional):
array fields
The Supplemental Data Table fields
-
suppData(optional):
object suppData
Metadata about the Supplemental Table
Nested Schema : suppData
Type:
object
Metadata about the Supplemental Table
Show Source
-
folderName(optional):
string
The name of the folder in which the Supplemental Data Table exists
-
objectName(optional):
string
The name of the Supplemental Data Table
Nested Schema : items
Type:
Show Source
object
-
fieldName(optional):
string
The supplemental data field name
-
fieldType(optional):
string
The supplemental data field type
Examples
For an existing supplemental table, you can get only the primary key field names or all of the field names.
FIELDS | DESCRIPTION |
---|---|
Authorization | <AUTH_TOKEN> |
REQUEST NOTES
- Use the
ft
fields to be returned in the response. By default, all fields are sent. To get only the primary key fields, setft=pk
.
Sample Request
To get only the primary key fields for a supplemental table named MyExampleSuppTable in the folder MyExampleFolder, a client application sent a GET request as follows:
GET /rest/api/v1.3/folder/MyExampleFolder/suppData/MyExampleSuppTable?ft=PK
RESPONSE NOTES
- The system returns an array of fields. Depending on the
ft
query parameter, the response will send either all of the fields or only the primary key fields. For each field returned, the key-value pairs arefieldName
andfieldType
(data type of the field). - The system returns an array of
suppData
objects. These objects contain the data for the supplemental table:objectName
: Name of the supplemental tablefolderName
: Name of the folder containing the supplemental table
Sample Response: Success
To get only the primary key fields for a supplemental table named MyExampleSuppTable in the folder MyExampleFolder, a client application requested only the primary fields by specifying
ft=PK
as a query parameter. The system sent the following response, where the fields array contains the primary key field names and their types. In this example, the supplemental table had one primary key field,
MyPKfield1
, of type
STR500
. The
suppData
object echoes back the folder name and supplemental table name sent in the request.
HTTPS response status code: 200 OK { "fields": [ { "fieldName": "MyPKfield1", "fieldType": "STR500" } ], "suppData": { "folderName": "MyExampleFolder", "objectName": "MyExampleSuppTable" }, "links": [ { "rel": "self", "href": "/rest/api/v1.3/folder/MyExampleFolder/suppData/MyExampleSuppTable", "method": "GET" }, { "rel": "mergeTableMembers", "href": "/rest/api/v1.3/folders/MyExampleFolder/suppData/MyExampleSuppTable/members", "method": "POST" }, { "rel": "retrieveTableMembers", "href": "/rest/api/v1.3/folders/MyExampleFolder/suppData/MyExampleSuppTable/members", "method": "GET" }, { "rel": "deleteTableMembers", "href": "/rest/api/v1.3/folders/MyExampleFolder/suppData/MyExampleSuppTable/members", "method": "DELETE" } ] }
Troubleshooting error responses
The folder does not exist for the Responsys account. A
404 not found error is returned with the following error response body (where the folder name sent is returned in the square brackets):
{"type":"", "title":"Folder not found", "errorCode":"FOLDER_NOT_FOUND", "detail":"Folder name [MyExampleFolder] does not exist", "errorDetails":[]}
The table does not exist for the Responsys account. A
404 not found error is returned with the following error response body (where the table name sent is returned in the square brackets):
{"type":"", "title":"Resource not found", "errorCode":"RESOURCE_NOT_FOUND", "detail":"Supplemental name [MyExampleSuppTable] does not exist", "errorDetails":[]}
An invalid query parameter is sent (that is,
ft
is set to a value other than
pk
). A
400 bad request error is returned with the following error response body:
{"type":"", "title":"Invalid request parameters", "errorCode":"INVALID_PARAMETER", "detail":"Not a valid value for Request parameter ft. Allowed value is PK", "errorDetails":[]}
For accounts enabled for Organizational Access Control, the system applies the organization filter. So when a user belonging to an organization tries to invoke the API on a supplemental table belonging to another organization, the system returns the following error (where the table name sent is returned in the square brackets):
{"type":"", "title":"Resource not found", "errorCode":"RESOURCE_NOT_FOUND", "detail":"Supplemental name [OtherOrgExampleSuppTable] does not exist", "errorDetails":[]}