SOAP Data Tables with Web Services 1.0
Overview
You can generate a skeleton input for each operation in the Data Tables WSDL, which contains the following operations:
- add
- update
- modify
- get
- delete
- deploy
For each operation, there are 3 fields that are always required in the header:
- sessionID
- category: Data Table
- schemaLocation
SOAP API | Description | Required Input Variable | Success Response Variable | Fail Response Variable |
---|---|---|---|---|
add | Adds a record to a Data Table. |
Rows that need to be added (example): <bm:each_record> <bm:currencyCode>USD</bm:CurrencyCode> <!--currencyCode is a column in the table-->
<bm:conversionRate>1.0</bm:conversionRate> </bm:each_record> |
|
exceptionCode exceptionMessage |
get | Returns a specified record in the criteria from the selected Data Table. You can only retrieve 300 rows at a time using a 'get' call on a Data Table. |
|
|
exceptionCode exceptionMessage |
modify
|
The "modify" action will insert or update a data table row based on the actual Id of the row, whether that is the Natural Key or the row Id. When a Natural Key or row Id is provided the row will be updated; otherwise, a new row will be inserted into the data table.
|
|
status
|
|
<urn:modify> <urn:DataTables urn:table_name="SOAPSingleKey"> <urn:each_record> <urn:StringIndexKey>CPQCS-72139</urn:StringIndexKey> <urn:Int>2</urn:Int> <urn:Flo>2.0</urn:Flo> </urn:each_record> </urn:DataTables> </urn:modify> |
<bm:modifyResponse xmlns:bm="urn:soap.bigmachines.com"> <bm:status> <bm:success>true</bm:success> <bm:message>Fri Jul 28 09:52:24 PDT 2017 - Successfully processed API for slc13kwz</bm:message> <bm:records_read>1</bm:records_read> <bm:records_failed>0</bm:records_failed> <bm:records_deleted>0</bm:records_deleted> <bm:records_inserted>0</bm:records_inserted> <bm:records_updated>1</bm:records_updated> </bm:status> </bm:modifyResponse> |
|
||
<urn:modify> <urn:DataTables urn:table_name="Table4SOAP"> <urn:each_record> <urn:State>CPQCS-72136</urn:State><urn:TranslatedState>Translation</urn:TranslatedState> <urn:Freight>72136</urn:Freight> <urn:Tax>0.0</urn:Tax> </urn:each_record> </urn:DataTables> </urn:modify> |
<bm:modifyResponse xmlns:bm="urn:soap.bigmachines.com"> <bm:status> <bm:success>true</bm:success> <bm:message>Fri Jul 28 09:50:21 PDT 2017 - Successfully processed API for slc13kwz</bm:message> <bm:records_read>1</bm:records_read> <bm:records_failed>0</bm:records_failed> <bm:records_deleted>0</bm:records_deleted> <bm:records_inserted>1</bm:records_inserted> <bm:records_updated>0</bm:records_updated> </bm:status> </bm:modifyResponse> |
|
||
update | Adds an existing record in a given Data Table. If you performing an update and your natural keys do not match, it will result in an error message. |
|
|
exceptionCode exceptionMessage |
delete | Deletes a record in a given Data Table. |
|
|
exceptionCode exceptionMessage |
deploy | Deploys a given Data Table and adds an entry in the script table about the selected Data Table. |
|
|
exceptionCode exceptionMessage |
Supported Basic SQL Standard Comparators
Comparator | Notes |
---|---|
< | Less than |
> | Greater than |
= | Equals |
!= |
Not Equals. With CDATA tags, we can use <> |
Like | Use for string fields. |
In | Use for locating numeric data |
Where Clause |
Administration
Accessing Users WSDL and Generating Skeleton Input
- Navigate from Admin Home Page > Integration Platform > Web Services.
- Click the Data Tables tab.
- Select an API from the drop-down menu.
- Choose a Data Table from the Table Name: drop-down menu.
- Enter a Record ID, if required.
- Click Generate Input to retrieve the skeleton.
Sample Data Tables APIs
<?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Header> <bm:userInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:sessionId>12E05E5C9FE4F5EF0C1D07E006B465F1</bm:sessionId> </bm:userInfo> <bm:category xmlns:bm="urn:soap.bigmachines.com">Data Tables</bm:category> <bm:xsdInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:schemaLocation>https://pm.bigmachines.com/bmfsweb/pm/schema/v1_0/datatables/ApproverEmails.xsd</bm:schemaLocation> </bm:xsdInfo> </soapenv:Header> <soapenv:Body> <bm:add xmlns:bm="urn:soap.bigmachines.com"> <bm:DataTables bm:table_name="ApproverEmails"> <bm:each_record> <bm:approvalStep>1</bm:approvalStep> <bm:emailAddress>jtam@bigmachines.com</bm:emailAddress> <bm:is_valid>1</bm:is_valid> </bm:each_record> </bm:DataTables> </bm:add> </soapenv:Body> </soapenv:Envelope>
<?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Header> <bm:userInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:sessionId>12E05E5C9FE4F5EF0C1D07E006B465F1</bm:sessionId> </bm:userInfo> <bm:category xmlns:bm="urn:soap.bigmachines.com">Data Tables</bm:category> <bm:xsdInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:schemaLocation>https://pm.bigmachines.com/bmfsweb/pm/schema/v1_0/datatables/ApproverEmails.xsd</bm:schemaLocation> </bm:xsdInfo> </soapenv:Header> <soapenv:Body> <bm:update xmlns:bm="urn:soap.bigmachines.com"> <bm:DataTables bm:table_name="ApproverEmails"> <bm:each_record> <bm:id>4133257</bm:id> <bm:approvalStep>1</bm:approvalStep> <bm:emailAddress>jtam@bigmachines.com</bm:emailAddress> <bm:is_valid>1</bm:is_valid> </bm:each_record> </bm:DataTables> </bm:update> </soapenv:Body> </soapenv:Envelope>
<?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Header> <bm:userInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:sessionId>12E05E5C9FE4F5EF0C1D07E006B465F1</bm:sessionId> </bm:userInfo> <bm:category xmlns:bm="urn:soap.bigmachines.com">Data Tables</bm:category> <bm:xsdInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:schemaLocation>https://pm.bigmachines.com/bmfsweb/pm/schema/v1_0/datatables/ApproverEmails.xsd</bm:schemaLocation> </bm:xsdInfo> </soapenv:Header> <soapenv:Body> <bm:update xmlns:bm="urn:soap.bigmachines.com"> <bm:DataTables bm:table_name="ApproverEmails"> <bm:each_record> <bm:id>4133257</bm:id> <bm:approvalStep>1</bm:approvalStep> <bm:emailAddress>jtam@bigmachines.com</bm:emailAddress> <bm:is_valid>1</bm:is_valid> </bm:each_record> </bm:DataTables> </bm:update> </soapenv:Body> </soapenv:Envelope>
<?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Header> <bm:userInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:sessionId>12E05E5C9FE4F5EF0C1D07E006B465F1</bm:sessionId> </bm:userInfo> <bm:category xmlns:bm="urn:soap.bigmachines.com">Data Tables</bm:category> <bm:xsdInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:schemaLocation>https://pm.bigmachines.com/bmfsweb/pm/schema/v1_0/datatables/ApproverEmails.xsd</bm:schemaLocation> </bm:xsdInfo> </soapenv:Header> <soapenv:Body> <bm:get xmlns:bm="urn:soap.bigmachines.com"> <bm:DataTables bm:table_name="ApproverEmails"> <bm:criteria> <bm:field>approvalStep</bm:field> <bm:value>1</bm:value> <bm:comparator>=</bm:comparator> </bm:criteria> <bm:criteria> <bm:field>emailAddress</bm:field> <bm:value>jtam@bigmachines.com</bm:value> <bm:comparator>=</bm:comparator> </bm:criteria> <bm:criteria> <bm:field>date_added</bm:field> <bm:value>2008-12-01 15:57:13</bm:value> <bm:comparator>=</bm:comparator> </bm:criteria> <bm:criteria> <bm:field>date_modified</bm:field> <bm:value>2009-09-29 04:28:25.0</bm:value> <bm:comparator>=</bm:comparator> </bm:criteria> </bm:DataTables> </bm:get> </soapenv:Body> </soapenv:Envelope>
When you select deploy, you'll no longer have the option to select Punchin URL, you will just select the Product Family you wish to deploy.
<?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Header> <bm:userInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:sessionId>12E05E5C9FE4F5EF0C1D07E006B465F1</bm:sessionId> </bm:userInfo> <bm:category xmlns:bm="urn:soap.bigmachines.com">Data Tables</bm:category> <bm:xsdInfo xmlns:bm="urn:soap.bigmachines.com"> <bm:schemaLocation>https://pm.bigmachines.com/bmfsweb/pm/schema/v1_0/datatables/ApproverEmails.xsd</bm:schemaLocation> </bm:xsdInfo> </soapenv:Header> <soapenv:Body> <bm:deploy xmlns:bm="urn:soap.bigmachines.com"> <bm:DataTables bm:table_name="ApproverEmails"/> </bm:deploy> </soapenv:Body> </soapenv:Envelope>