Authentication
SAP Ariba is a hybrid element using an authentication workflow using both OAuth2.0 and cXML services. The list of resources supported by either types of authentication are discussed further down below.
Using OAuth 2
One of the two types of authentication utilized by the SAP Ariba element is OAuth2.0, which uses an API key and Base64 encoded Client ID and Client Secret. Unlike other elements, SAP Ariba provides you with a different set of auth credentials for each API module. Currently, we support the following objects:
- contract-workspaces
- document-changes
- invoices
- pending-approvables
- purchase orders
SAP Ariba’s API modules are broadly classified into these categories:
- Analytics
- Ariba Network
- Catalog
- Procurement
- Strategic Resourcing
- Supplier Management
Each module itself has different API sub-categories under it; accordingly, you will need a different set of authentication credentials to access different objects. In our element, we use the following API sub-categories to access each object:
Object | API Sub Category | Category |
---|---|---|
ContractWorkspaces |
| Strategic Resourcing |
Invoices | Ariba Network Invoice Header Data Extraction API | Ariba Network |
DocumentChanges | Document Approval API | Procurement |
PendingApprovables | Document Approval API | Procurement |
PurchaseOrders | Ariba Network Purchase Order API | Ariba Network |
To access each object in the element, user will have to register an application for each of the above mentioned APIs. To register an application:
- Login to your registered Ariba developer account.
- Access the ‘Manage’ tab on the left of the screen.
- Click on ‘+’ to add a new application.
- A screen pops up asking for the ‘application name’ and ‘description’. Enter them.
- An application will be created.
Once an application is created, you now need access to the APIs.
- From the ‘Actions’ button, click on ‘Request API access’.
- On the new screen, select an API from the list. This API is nothing but the sub-category item we talked about in the table above. You can fill in other optional fields which includes realm name, AN-ID and realm type which are the details of your account. You can also include some comments describing why you need API access. Fill in appropriate details on the screen and click ‘Submit’.
- Your application will now be sent to review and will be approved by the Ariba team.
- Once the app is approved, you will now have access to the data from the API calls.
- Now, to generate the auth credentials click Generate OAuth Secret.
This will give you an ‘API key’ and ‘Base64 encoded Client ID and Client Secret’ which is what you require for creating an instance.
Using cXML
On certain resources, SAP Ariba supports only GET calls but the SAP Ariba element on our platform leverages the cXML services of the Ariba system and implements POST/PATCH/DELETE calls on the 'purchaseOrders' and POST/DELETE on the 'invoices' objects, respectively. These calls do not have any dependency on the OAuth2.0 authentication used while provisioning an instance. The above mentioned cXML calls require you to pass the credentials in the header section of the request payload. Below is a sample header that is required to pass in the request payload:
<Header>
<From>
<Credential
domain="NetworkId">
<Identity>ANxxxxxxxx-T</Identity>
</Credential>
<Credential
domain="SystemID">
<Identity>Default</Identity>
</Credential>
</From>
<To>
<Credential
domain="NetworkId">
<Identity>ANxxxxxxxx-T</Identity>
</Credential>
<Credential
domain="internalsupplierid">
<Identity>xxxxxxxxx</Identity>
</Credential>
<Credential
domain="buyersystemid">
<Identity>xxxxxxxxx</Identity>
</Credential>
<Credential
domain="sap">
<Identity>xxxxxxxxx</Identity>
</Credential>
</To>
<Sender>
<Credential domain="AribaNetworkUserId">
<Identity>ANxxxxxxxx-T</Identity>
<SharedSecret>xxxxxxxxx</SharedSecret>
</Credential>
<UserAgent>Buyer xxxx</UserAgent>
</Sender>
</Header>
Authentication Parameters
You can authenticate an element instance using the UI or via API calls. For detailed information on how to authenticate an instance, see our related documentation:
To authenticate an instance of the SAP Ariba element, you may need any of the following parameters:
Parameter Name | API Value | Description |
---|---|---|
contractWorkspaces.apiKey | Contract Workspaces API key. | |
contractWorkspaces.base64ClientIdAndSecret | ||
Document Approval API Key | documentApproval.apiKey | Document Approval API Key. |
Document Approval Base64 Client Id and Secret | documentApproval.base64clientidandsecret | Document Approval Base64 Client Id and Secret. |
Domain | domain | Domain for SAP Ariba. |
Invoices API Key | invoices.apiKey | Invoices API Key. |
Invoices Base64 Client Id and Secret | invoices.base64ClientIdAndSecret | Invoices Base64 Client Id and Secret. |
Purchase Orders API Key | purchaseOrders.apiKey | Purchase Orders API Key. |
Purchase Orders Base64 Client Id and Secret | purchaseOrders.base64ClientIdAndSecret | Purchase Orders Base64 Client Id and Secret. |
Shared Secret | sharedSecret | SAP Ariba Shared Secret. |
Default Select Fields | default.select.fields.map | Generic map used to specify default fields for bulk download and GET /all requests. Each key should be the canonical objectName and values may be specified as a comma-delimited string or a list of strings. |
Instance Variables | instance.variables | States what the instance variables are. |
Synchronous Bulk Notification | synchronous.bulk.notification | Enables synchronous bulk callback notification. |
Filter null values from the response | filter.response.nulls | Used to enable/disable filtering of null values from the responses. |
Sample Configuration JSON
"configuration": {
"filter.response.nulls": "true",
"domain": "NetworkId",
"synchronous.bulk.notification": "true",
"contractWorkspaces.apiKey": "<MyContractWorkspaceApiKey>",
"sharedSecret": "******",
"purchaseOrders.base64ClientIdAndSecret": "xxxxxxxxxxxx",
"purchaseOrders.apiKey": "<MyPurchaseOrdersApiKey>",
"invoices.base64ClientIdAndSecret": "xxxxxxxxx",
"invoices.apiKey": "<MyInvoicesApiKey>",
"documentApproval.base64clientidandsecret": "xxxxxxxxxxx",
"documentApproval.apiKey": "<MyDocumentApproval>",
"contractWorkspaces.base64ClientIdAndSecret": "xxxxxxxxxxxx"
}
Element Fact Sheet and Reference
Authentication and Configuration Parameters
To see all authentication parameters for the SAP Ariba element, follow these steps:
- Sign in to Cloud Elements and navigate to Elements.
- Hover over the card for an element, and then click My Resources.
- In the top navigation toolbar, click Setup.
- From the 'Setup' page, you can view a complete list of the element's authentication and configuration parameters.
Element Resources
In order to provide users with normalized APIs across Hubs, Cloud Elements resources were mapped to the following Vendor resources:
CE Placeholder | CE Method | CE Resource | Vendor Method | Vendor Resource |
---|---|---|---|---|
Purchase Orders | GET | /purchase-orders | GET | /purchase-orders |
POST | /purchase-orders | POST | <cXML of PO> | |
PATCH | /purchase-orders/{id} | POST | <cXML of PO> | |
DELETE | /purchase-orders/{id} | POST | <cXML of PO> | |
Invoices | GET | /invoices | GET | /invoices |
POST | /invoices | POST | <cXML of invoices> | |
PATCH | /invoices/{id} | POST | <cXML of invoices> | |
DELETE | /invoices/{id} | POST | <cXML of invoices> | |
Contract Workspaces | GET | /contract-workspaces | GET | /contract-workspaces |
Document Approvals | GET | /approvals | /changes | |
GET | /pending-approvals | /pendingApprovables |
/contractworkspaces
currently only works with minimum payload and does not support maximum payload. Request payloads for these methods containing custom fields or department array fields will fail with a 400 error. Events and Supported Resources
The SAP Ariba Element does not support any events.
Bulk
Bulk provides an option to upload a large number of resources, such as contacts, to a service provider all at once. You can use bulk to download a csv or json file from a large number of records or upload a csv or json file to add multiple records.
Bulk Information | Details |
---|---|
Bulk Type | Cloud Elements bulk service and not native bulk endpoints. Rate limits come into play when using the Cloud Elements bulk service, so review the limitations in the API provider's documentation. |
Objects that Support Bulk | /purchase-orders , /invoices |
Field Selection Support | No. To limit the fields returned by the query, you must use a transformation. For example, you can use only select * for this element. |
Order By Support | No. |
Querying
The Cloud Elements Query Language ( CEQL ) provides a standard way to search across all of our elements. Rather than having users research how to query each resource at a provider, we've normalized your search experience. Cloud Elements translates your queries to the API provider's search syntax. CEQL represents the "where" portion of a typical query that can include many other components like field selection, sorting, and pagination. For more details on Querying, see Querying with CEQL.
To determine whether where clause is supported for an object, you can make an API call to object/{objectName}/metadata
while providing the Element version and check for "filterable"="true".
SAP Ariba Element supports querying for the following objects:
- GET/contract-workspaces
- GET/invoices
- GET/purchase-orders
Element Extension
Element Builder gives you the integration tools to extend the current feature set of any of our elements by adding a resource or method. If your use case requires a resource our element doesn’t currently support, you can easily add it in yourself using Element Builder.
SAP Ariba is an extendable element, meaning you can customize it according to your needs; for more information, see Extending Elements.
Discovery APIs
Discovery APIs are usually used in conjunction with a specific authenticated element instance to:
- Identify data objects in an element
- Identify data objects and their source (the vendor, a VDR, or Cloud Elements library)
- Find metadata, including custom fields, related to an object
- Retrieve the Open API specifications (API docs) of an object
However, Discovery APIs are not supported by Cloud Elements for the SAP Ariba element, as there is no support by the vendor for the same.
Element API Documentation
The base URL for all API requests is https://api.cloud-elements.com/elements/api-v2
.
Provider Documentation
To get access the vendor documentation, the users have to login into https://developer.ariba.com/api/home
The API documentation for SAP Ariba is private, where the users have to reach out to SAP support to register and get access to it. Please follow the link to register for the developer portal https://help.sap.com/viewer/b61dd8c7e22c4fe489f191f66b4c48d6/cloud/en-US/3ea9ef42eb074716a1fd91cf9444727b.html.
However, as an alternate, users can read the content from https://api.sap.com/package/SAPAribaOpenAPIs?section=Artifacts to get more information on the Ariba APIs.