Delete Supplemental Table member based on a query attribute
delete
/rest/api/v1.3/folders/{folderName}/suppData/{tableName}/members
Deletes a Supplemental Table member based on a query attribute. A maximum of one record is deleted per request.
Request
Path Parameters
-
folderName: string
Folder name
-
tableName: string
Table name
Query Parameters
-
id: string
IDs corresponding to the query attribute. All the primary key values of the Supplemental Table must be specified by repeating this parameter. The order of the values must match the order of the primary keys specified in the 'qa' parameter.
-
qa: string
Query attribute. All of the primary key fields of the Supplemental Table must be specified by repeating this parameter. Do not include other fields.
Response
Supported Media Types
- application/json
Default Response
Root Schema : Supplemental Table members with PK
Type:
object
Title:
Show Source
Supplemental Table members with PK
-
insertOnNoMatch(optional):
boolean
Specifies whether a member record should be inserted into the Supplemental Table if it does not already exist.
-
recordData(optional):
object recordData
Record data that represents field names and corresponding values for the member.
-
required(optional):
-
updateOnMatch(optional):
string
Allowed Values:
[ "REPLACE_ALL", "NO_UPDATE" ]
Specifies whether a member record should be updated in the Supplemental Table if it already exists.
Nested Schema : recordData
Type:
object
Record data that represents field names and corresponding values for the member.
Show Source
-
fieldNames:
array fieldNames
Field names in the Supplemental Table
-
mapTemplateName(optional):
string
The map template in Responsys that can be used to map field names of the Supplemental Table to column names.
-
records:
array records
Array of values corresponding to the fieldNames. Each element in the array represents a single member.
Nested Schema : records
Type:
array
Array of values corresponding to the fieldNames. Each element in the array represents a single member.
Show Source
-
Array of:
array items
Field values for the member in the Supplemental Table
Examples
Tip:
Need Higher API Call Limits? We have an API on Asynchronous API with the same functionality. Please use the Asynchronous Delete Supplemental Table Members API.This interface is to delete a Supplemental Table Records by specifying the primary key using request parameters.
FIELDS | DESCRIPTION |
---|---|
Authorization | <AUTH_TOKEN> |
FIELDS | DESCRIPTION |
---|---|
qa | Query Attribute-All the Primary Keys of the Supplemental Table must be specified by repeating this parameter. Do not send other field names. |
id | IDs corresponding to the query attribute. All the Primary Key Values of the Supplemental Table must be specified by repeating this parameter. The order of the values must match the order of the Primary Keys specified in the "qa" parameter. |
Sample Request URL:
rest/api/v1.3/folders/DemoNewsLetter/suppData/CompositePKSuppTable/members?qa=PK1&qa=PK2&qa=PK3&fs=PK1,PK2,PK3,F1,F2&id=1&id=1&id=1
Sample Response: Success
NOTES:
- The response will always contain all the query attributes specified in the request parameter in the "fieldNames" attribute and the corresponding values for the records in the "records" attribute in case the deletion of that record is successful.
- In case a record is not found for the given id, an error response saying "No Records found for the Id" is returned.
- In case a record is found and delete failed for some reason, the record in the response contains an error message starting with "DELETEFAILED:". Client developers can look for the string "DELETEFAILED:" in the response for a particular row to determine whether that record was deleted successfully or not.
- Other attributes in the response like mapTemplateName, insertOnNoMatch, updateOnMatch and matchColumn will have default values (null/false).
{ "recordData":{ "fieldNames":[ "PK1", "PK2", "PK3" ], "records":[ [ "1", "1", "1" ] ], "mapTemplateName":null }, "insertOnNoMatch":false, "updateOnMatch":null, "links":[ { "rel":"self", "href":"/rest/api/v1.3/folders/DemoNewsLetter/suppData/CompositePKSuppTable/members?qa=PK1&qa=PK2&qa=PK3&fs=PK1,PK2,PK3,F1,F2&id=1&id=1&id=1", "method":"DELETE" }, { "rel":"mergeTableMembers", "href":"/rest/api/v1.3/folders/DemoNewsLetter/suppData/CompositePKSuppTable/members", "method":"POST" } ] }
Sample Response: Failure
{ "type": "", "title": "Record not found", "errorCode": "RECORD_NOT_FOUND", "detail": "No records found in the table for the given ids", "errorDetails": [] }
Sample Response in case not ALL Primary Key Columns are specified in the "qa" request parameter:
{ "type": "", "title": "Invalid request parameters", "errorCode": "INVALID_PARAMETER", "detail": "All and Only the Primary Keys in the Table [PK1, PK2, PK3] must be specified as Query Columns.", "errorDetails": [] }
Limits
One record can be deleted per request. To delete more records at once, leverage the SOAP API, which can delete up to 200 records.