Report Services

This topic describes how to execute a JDE report (UBE) using the execute report web service.

The following are required:

  • Your application must have obtained a session ID. If not, review the Login Services topic before continuing with this section.

  • The report you are calling has already been defined using the Cantara Console. See Managing Reports, for more details.

You can execute a report by calling the service listed below with a payload that follows the Report Request definition (at a minimum the payload requires a report name, and parameter). If the execution is successful, Cantara returns a response that follows the Report Response definition. If there is a failure, Cantara returns an error. See the Error Message topic for more information.

Each report execution requires one or more parameters based on their definition on the Cantara server (see Managing Reports). Although there multiple parameters defined for reports, only the ones marked as Required need to be included in the payload.

To information about obtaining the definition for a report see Login Services

Reports

Endpoint: http(s)://[hostname]:[port]/[context]/service/[version]/report/[environment]

Method: POST

Content-Type: application/json or application/xml

Accept: application/json or application/xml

Path Parameters

Parameter

Description

hostname

Cantara worker hostname

port

Cantara worker listening port (only required if non-standard HTTP/s port

context

Cantara worker web application context

version

Cantara worker API version

environment

Cantara access environment. Refer to the 

Managing Environments

topic for more information.(Example - E1DEV)

Info

In your payload you can have parameters and criteria parametersParameters map to a UBE's processing options and data selection. Criteria parameters map to a UBE's report interconnects.

Note:

Environment refers to the Cantara Access Server environment you are trying to login to. For example, E1DEV. You would have previously configured this when you set up your environments. See the Managing Environments topic for more information.

You can obtain a list of configured environments by using the console to Search for an Environment.

On This Page



JavaScript
{
	"name": "PurchaseOrder",
	"cantaraVersion": "5.1",
	"tenantId": "",
	"apiKey": "",
	"parameter": [],
	"criteriaParameter": [
		{
			"criteriaLiteral": [
				""
			],
			"name": "Documentorderinvoice"
		},
		{
			"criteriaLiteral": [
				""
			],
			"name": "StatusCodeNext"
		}
	],
	"printImmediate": false,
	"batchQueue": "QBATCH",
	"createCSV": false
}




Request Body Parameters

Path

Description

name

Report service name

cantaraVersion

Cantara platform version

tenantId

Cantara Tenant ID (The Tenant ID and API Key can be retrieved from the customer portal.)

apiKey

Cantara Tenant API Key (The Tenant ID and API Key can be retrieved from the customer portal.)

Parameter/criteria parameter

Report request parameters

printImmediate

To print reports

batchQueue

Override JDE batch execution queue 

createCSV

To create CSV file



Execute Reports

Example for executing Reports service - PurchaseOrder Report

Example Endpoint: https://us.cantara.cloud/cantara/serivce/50/report/E1DEV

In this example we will call the Purchase Order print UBE (R43500).

Before building our payload we need to view the required parameters and criteria parameters for the purchase order print UBE. By looking at the reports definition in the Cantara console we can see that one of the criteria parameters is the StatusCodeNext and one of the parameters is the Documentorderinvoice.

With this information we can now call the report service.

JavaScript
{
	"name": "PurchaseOrder",
	"cantaraVersion": "5.1",
	"tenantId": "",
	"apiKey": "",
	"parameter": [],
	"criteriaParameter": [
		{
			"criteriaLiteral": [
				"12345"
			],
			"name": "Documentorderinvoice"
		},
		{
			"criteriaLiteral": [
				"999"
			],
			"name": "StatusCodeNext"
		}
	],
	"printImmediate": false,
	"batchQueue": "QBATCH",
	"createCSV": false
}
JavaScript
{
	"Message": {
		"value": "Transaction Successful",
		"origin": "Worker7@6c101b96c994",
		"type": 0,
		"sessionId": "",
		"cantaraSid": "0a7eb2d5-baef-4dd2-9a39-d6d691e1f8e9"
	},
	"name": "PurchaseOrder",
	"jobId": 152,
	"reportName": "R43500",
	"reportVersion": "XJDE0001"
}