0% found this document useful (0 votes)
2 views

AsynchronousRequestsManagementAPI

The document provides a guide for implementing the Asynchronous Requests Management API for SAP Ariba, detailing how to monitor and manage asynchronous job requests. It includes information on prerequisites, endpoints for querying job status and downloading error files, and response codes. Additionally, it outlines legal disclaimers and restrictions related to the use of the API.

Uploaded by

Sergio Manchado
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

AsynchronousRequestsManagementAPI

The document provides a guide for implementing the Asynchronous Requests Management API for SAP Ariba, detailing how to monitor and manage asynchronous job requests. It includes information on prerequisites, endpoints for querying job status and downloading error files, and response codes. Additionally, it outlines legal disclaimers and restrictions related to the use of the API.

Uploaded by

Sergio Manchado
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

PUBLIC

Document Version: 2408 – 2025-01

Asynchronous Requests Management API


SAP Ariba APIs
SAP Ariba Developer Portal
© 2025 SAP SE or an SAP affiliate company. All rights reserved.

SAP Ariba Contracts

THE BEST RUN


Content

Asynchronous Requests Management API. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3


Endpoints included in the Asynchronous Requests Management API. . . . . . . . . . . . . . . . . . . . . . . . . . . .4
Workflow for the Asynchronous Requests Management API. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
Getting the Status of an Asynchronous Job Using the Asynchronous Requests Management API. . . . . . . .4
Downloading the Error File of a Failed Job Request Using the Asynchronous Requests Management
API. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Response Codes Returned by Asynchronous Job Requests API. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7
API-Specific Disclaimers and Legal Information. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

Asynchronous Requests Management API


2 PUBLIC Content
Asynchronous Requests Management API

This guide is for a customer developer intending to implement the Asynchronous Requests Management API in a
client application to:

• Monitor job requests that are running asynchronously and initiated by APIs like the Contract Line Items Import
API and the Contract Workspace State Change API.
• Get the status of an ongoing job request and download the error files for failed job requests.

This guide applies to:

• SAP Ariba APIs


• SAP Ariba developer portal
• SAP Ariba Contracts
• SAP Ariba Strategic Sourcing Suite

Prerequisites

• To create an application and request access to use the SAP Ariba APIs relevant to this feature, you must have
access to the SAP Ariba developer portal. For details refer to Steps to Start Using the SAP Ariba APIs in Help
for the SAP Ariba Developer Portal.
• All queries made to this API must be authenticated using OAuth authentication. For details refer to SAP Ariba
Developer Portal Authentication in Help for the SAP Ariba Developer Portal.
• User whose credentials are passed in the API call must be the initiator of the job or must have permissions to
view the job.

Restrictions

The size of the error file that can be downloaded using the API cannot exceed 2 MB.

Asynchronous Requests Management API


Asynchronous Requests Management API PUBLIC 3
Endpoints included in the Asynchronous Requests
Management API
This topic describes the endpoints supported by the Asynchronous Requests Management API.

Endpoint Description

GET /jobs/{jobId} Queries the status of the asynchronous job request initiated by
an API for the specified job ID.

For more information, see Getting the Status of an Asynchro-


nous Job Using the Asynchronous Requests Management API
[page 4].

GET /jobs/{jobId}/errors Downloads the error file generated for the specified job ID.

For more information, see Downloading the Error File of a


Failed Job Request Using the Asynchronous Requests Manage-
ment API [page 6].

Workflow for the Asynchronous Requests


Management API
This topic describes the workflow of the Asynchronous Requests Management API.

1. The client application queries the status of the asynchronous job request initiated by an API for the specified
job ID using the GET /jobs/{jobId} endpoint.
2. If the job request for the specified job ID has failed, an error file is available. The client application downloads
the error file using the GET /jobs/{jobId}/errors endpoint by providing the job ID.

Getting the Status of an Asynchronous Job Using the


Asynchronous Requests Management API
The Asynchronous Requests Management API can be implemented in a client application to get the status of an
asynchronous job request initiated by an API.

Prerequisites

To get the status of an asynchronous job, you must have the ID of the job.

Asynchronous Requests Management API


4 PUBLIC Asynchronous Requests Management API
Context

An asynchronous job request initiated by an API runs as an independent process in the background. To track
the progress of such job requests, you can use the Asynchronous Requests Management API. The GET /jobs/
{jobId} endpoint enables you to get the current status of any asynchronous job request.

 Note

In the sample URLs in this topic, replace {{runtime_url}} with the desired runtime URL from the
Environment Details table on the SAP Ariba developer portal discovery page for this API.

Procedure

Invoke the GET /jobs/{jobId} endpoint.

 Example

GET {{runtime_url}}/jobs/QHFHUUF6BMJDIXFxSA?
user=myUser&passwordAdapter=myPassword&realm=mySite

Where,
• user, is the unique name of the user on whose behalf the API call is invoked. This is a required parameter.
• passwordAdapter, is the password adapter for authenticating the user on whose behalf the request was
initiated. This is a required parameter.
• realm, is the SAP Ariba Contracts site to which the API request is sent. This is a required parameter.

You can append the job ID in the URL or pass it like a parameter as a path variable.

Results

If the request is successful, the API returns the status of the job request corresponding to the specified job ID
along with other related details such as the submit time, start time, complete time, and the user who created the
asynchronous job request. For more information about the response codes returned by the API, see Response
Codes Returned by Asynchronous Job Requests API [page 7].

Asynchronous Requests Management API


Asynchronous Requests Management API PUBLIC 5
Downloading the Error File of a Failed Job Request
Using the Asynchronous Requests Management API
The Asynchronous Requests Management API can be implemented in a client application to download the error file
for a failed job request.

Prerequisites

To download the error file for a failed job request, you must have the ID of the job.

Context

The GET /jobs/{jobId}/errors endpoint of the Asynchronous Requests Management API enables you to
download the error file of a failed job request. You can download the error file in the available file format.

 Note

In the sample URLs in this topic, replace {{runtime_url}} with the desired runtime URL from the
Environment Details table on the SAP Ariba developer portal discovery page for this API.

Procedure

Invoke the GET /jobs/{jobId}/errors endpoint.

 Example

GET {{runtime_url}}/jobs/QHFHUUF6BMJDIXFxSA/errors?
user=myUser&passwordAdapter=myPassword&realm=mySite

Where,
• user, is the unique name of the user on whose behalf the API call is invoked. This is a required parameter.
• passwordAdapter, is the password adapter for authenticating the user on whose behalf the request was
initiated. This is a required parameter.
• realm, is the SAP Ariba Contracts site to which the API request is sent. This is a required parameter.

You can append the job ID in the URL or pass it like a parameter as a path variable.

Asynchronous Requests Management API


6 PUBLIC Asynchronous Requests Management API
Results

If the request is successful, one of the following occurs:

• If the response code is 200, the API returns the error file in the available file format, which specifies the reason
for the incomplete job request.
• If the response code is 204, the API doesn't return any error file, which indicates that either the job request was
successfully completed or there is no error file associated with the specified job ID.

If the request is unsuccessful, the API returns a appropriate response code. For more information about the
different response codes returned by the API, see Response Codes Returned by Asynchronous Job Requests API
[page 7].

Response Codes Returned by Asynchronous Job


Requests API
Refer to the following table for the different response codes returned by the Asynchronous Job Requests API.

Response Code Description

200 Success.

204 Error file not found for this job ID.

400 Bad Request.

401 Unauthorized user credentials.

403 User does not have the required permissions to access the
content.

404 Job ID not found.

API-Specific Disclaimers and Legal Information


The SAP Ariba developer portal included in the SAP Ariba APIs product and the APIs made available on this site are
provided solely at the discretion of SAP without warranty of any kind, and SAP may change, suspend, or cancel any
or all features or functions of the SAP Ariba APIs product or revise the website at any time. Any production use of
or commercialization of applications containing any APIs provided on this website is prohibited without a written
agreement between your company and SAP governing such activities.

Access to this API is available to you as a subscriber to this solution as part of the SAP Cloud Service Level
Agreement. However, it is not considered part of the solution. Use of this API is purely optional and is subject to
restrictions stated in the documentation, including the Terms of Use and the documentation found at the SAP
Ariba developer portal (see https://developer.ariba.com/api ). If you wish to connect a third-party service using
this API, first confirm that the company is participating in the SAP partner program and is authorized to provide a

Asynchronous Requests Management API


Asynchronous Requests Management API PUBLIC 7
connection to this solution using this API. You will be required to submit written consent to SAP to authorize the
exchange of data with the third-party service.

Asynchronous Requests Management API


8 PUBLIC Asynchronous Requests Management API
Important Disclaimers and Legal Information

Hyperlinks
Some links are classified by an icon and/or a mouseover text. These links provide additional information.
About the icons:

• Links with the icon : You are entering a Web site that is not hosted by SAP. By using such links, you agree (unless expressly stated otherwise in your agreements
with SAP) to this:

• The content of the linked-to site is not SAP documentation. You may not infer any product claims against SAP based on this information.

• SAP does not agree or disagree with the content on the linked-to site, nor does SAP warrant the availability and correctness. SAP shall not be liable for any
damages caused by the use of such content unless damages have been caused by SAP's gross negligence or willful misconduct.

• Links with the icon : You are leaving the documentation for that particular SAP product or service and are entering an SAP-hosted Web site. By using such links,
you agree that (unless expressly stated otherwise in your agreements with SAP) you may not infer any product claims against SAP based on this information.

Videos Hosted on External Platforms


Some videos may point to third-party video hosting platforms. SAP cannot guarantee the future availability of videos stored on these platforms. Furthermore, any
advertisements or other content hosted on these platforms (for example, suggested videos or by navigating to other videos hosted on the same site), are not within the
control or responsibility of SAP.

Beta and Other Experimental Features


Experimental features are not part of the officially delivered scope that SAP guarantees for future releases. This means that experimental features may be changed by
SAP at any time for any reason without notice. Experimental features are not for productive use. You may not demonstrate, test, examine, evaluate or otherwise use the
experimental features in a live operating environment or with data that has not been sufficiently backed up.
The purpose of experimental features is to get feedback early on, allowing customers and partners to influence the future product accordingly. By providing your feedback
(e.g. in the SAP Community), you accept that intellectual property rights of the contributions or derivative works shall remain the exclusive property of SAP.

Example Code
Any software coding and/or code snippets are examples. They are not for productive use. The example code is only intended to better explain and visualize the syntax and
phrasing rules. SAP does not warrant the correctness and completeness of the example code. SAP shall not be liable for errors or damages caused by the use of example
code unless damages have been caused by SAP's gross negligence or willful misconduct.

Bias-Free Language
SAP supports a culture of diversity and inclusion. Whenever possible, we use unbiased language in our documentation to refer to people of all cultures, ethnicities, genders,
and abilities.

Asynchronous Requests Management API


Important Disclaimers and Legal Information PUBLIC 9
www.ariba.com

Copyright © 2025 Ariba, Inc. All rights reserved.

This documentation, as well as the Ariba solutions, software and/or


services described in it, contain proprietary information. They are
provided under a license or other agreement containing restrictions on
use and disclosure and are also protected by copyright, patent and/or
other intellectual property laws. Except as permitted by such agreement,
no part of the document may be reproduced or transmitted in any form
by any means, electronic, mechanical or otherwise, without the prior
written permission of Ariba, Inc.

Ariba, Inc. assumes no responsibility or liability for any errors or


inaccuracies that may appear in the documentation. The information
contained in the documentation is subject to change without notice.

Ariba and Ariba products and services mentioned herein as well as


their respective logos are trademarks or registered trademarks of
Ariba, Inc. in the United States and other countries. Please see http://
www.ariba.com/legal/trademarks for additional trademark information
and notices.

Ariba Sourcing solutions (On Demand and software) are protected


by one or more of the following patents, including without limitation:
U.S. Patent Nos. 6,199,050; 6,216,114; 6,223,167; 6,230,146; 6,230,147;
6,285,989; 6,408,283; 6,499,018; 6,564,192; 6,871,191; 6,952,682;
7,010,511; 7,072,061; 7,130,815; 7,146,331; 7,152,043;7,225,152; 7,277,878;
7,249,085; 7,283,979; 7,283,980; 7,296,001; 7,346,574; 7,383,206;
7,395,238; 7,401,035; 7,407,035; 7,444,299; 7,483,852; 7,499,876;
7,536,362; 7,558,746; 7,558,752; 7,571,137; 7,599,878; 7,634,439;
7,657,461; 7,693,747; 8,364,577; and 8,392,317. Patents pending.

Other Ariba product solutions are protected by one or more of the


following patents:

U.S. Patent Nos. 6,199,050, 6,216,114, 6,223,167, 6,230,146, 6,230,147,


6,285,989, 6,408,283, 6,499,018, 6,564,192, 6,584,451, 6,606,603,
6,714,939, 6,871,191, 6,952,682, 7,010,511, 7,047,318, 7,072,061,
7,084,998; 7,117,165; 7,225,145; 7,324,936; 7,536,362; 8,364,577; and
8,392,317. Patents pending.

Certain Ariba products may include third party software or other


intellectual property licensed from a third party. For information
regarding software or other intellectual property licensed from a third
party, go to http://www.ariba.com/copyrights.cfm.

THE BEST RUN

You might also like