[go: up one dir, main page]

0% found this document useful (0 votes)
26 views2 pages

Rest API

The document outlines the structure and types of requests in REST APIs, specifically for logging in and retrieving user information from Informatica Cloud. It provides examples of both JSON and XML formats for login requests and the expected responses, including user details and session IDs. Additionally, it describes how to use the session ID to make further requests, such as obtaining license information or deleting schedules.

Uploaded by

iihtiics
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views2 pages

Rest API

The document outlines the structure and types of requests in REST APIs, specifically for logging in and retrieving user information from Informatica Cloud. It provides examples of both JSON and XML formats for login requests and the expected responses, including user details and session IDs. Additionally, it describes how to use the session ID to make further requests, such as obtaining license information or deleting schedules.

Uploaded by

iihtiics
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

Request header

Request body
Return lists

REST ; Representational state transfer: a type of API - Application programming


interface -

When you send a request, there is a structure : and you get a response back

Different type of requests:

POST: Sending a request for creating a record, login,


GET : get the details on the specific task.
PATCH : update records.

Base URL - https://dm-us.informaticacloud.com

POST https://dm-us.informaticacloud.com/ma/api/v2/user/login
Content-Type: application/json
Accept: application/json

{
"username": "user@informatica.com",
"password": "mypassword"
}
The login might return the following information:
{
"products": [
{
"name": "Integration Cloud",
"baseApiUrl": "https://pod.clouddev.informaticacloud.com/saas"
}
],
"userInfo": {
"sessionId": "9KA11tLGqxVcGeul8SQBK3",
"id": "9L1GFroXSDHe2IIg7QhBaT",
"name": "user",
"parentOrgId": "52ZSTB0IDK6dXxaEQLUaQu",
"orgId": "0cuQSDTq5sikvN7x8r1xm1",
"orgName": "MyOrg_INFA",
"groups": {},
"status": "Active"
}
}
You can then use the sessionId and the baseapiUrl to construct a request to obtain
your organization's license information, for example:
GET https://pod.clouddev.informaticacloud.com/saas/public/core/v3/license/org/
{orgId}
Content-Type: application/json
Accept: application/json

icSessionId=ezs5oLuMZsfiCEecw4Xgso

Activity Log :

GET https://usw5.dm-us.informaticacloud.com/saas/api/v2/activity/activityLog
============================

XML format example


You can use XML calls with version 2 resources.
To log in using XML, you might use the following header and body:
POST https://dm-us.informaticacloud.com/ma/api/v2/user/login
Content-Type: application/xml
Accept: application/xml

<login>
<username>useremail@company.com</username>
<password>mypassword</password>
</login>
The login might return the following information:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<user>
<id>00000B03000000000001</id>
<orgId>00000B</orgId>
<name>user@company.com</name>
<createTime>2012-06-14T15:00:00.000Z</createTime>
<updateTime>2012-06-14T15:00:00.000Z</updateTime>
<createdBy>System</createdBy>
<updatedBy>user@company.com</updatedBy>
<firstName>Firstname</firstName>
<lastName>Lastname</lastName>
<title>Senior Software Engineer</title>
<password>********</password>
<phone>11111111111111111111</phone>
<timezone>America/Los_Angeles</timezone>
<serverUrl>http://example.informatica.com/saas</serverUrl>
<icSessionId>IV4wOrJmd6YUtmKa8t</icSessionId>
</user>
You can then use the icSessionId and the serverUrl to construct a request to delete
a schedule as follows. The schedule ID is 000001D0000000000001.
DELETE http://example.informatica.com/saas/api/v2/schedule/000001D0000000000001
Accept: application/xml
icSessionId: IV4wOrJmd6YUtmKa8t

You might also like