To login you need to use an valid account who has permission to use the API.
Encrypting a plain text password
Link: https://au.itwocx.com/api/latest/api/help/index#!/Login/Login_EncryptPassword
Logging In with Email and Password
Link: https://au.itwocx.com/api/latest/api/help/index#!/Login/Login_ByEmail
By passing a valid email address and encrypted password you will receive a session key which can be used for all other interactions.
All requests require a valid user-agent header to pass through the web application firewall protecting iTWO cx.
e.g. User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36
Logging In with Azure Active Directory (AD) - Single Sign On (SSO)
If the user you want to login as belongs to a company who has configured Azure AD - Single Sign On (SSO), you will need to authenticate with Microsoft first to get a token which permits users to access the iTWOcx resource.
Authenticating with Microsoft to receive an Access Token is well documented here:
https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-overview
Depending on the authentication flow for the scenario being implemented you will need some or all of the following information:
Authority: https://login.microsoftonline.com/common
iTWOcx Resource: 52e5f8a4-8b0e-455f-9df4-5beb7c37dd18
ClientId: (GUID of the application configured for SSO in your Azure AD tenant)
ReturnUrl: https://au.itwocx.com/cxR/Authentication
Once you have an access token you would pass that token to iTWOcx by adding a header to the HTTP request:
Authorization: Bearer {accessToken}
This header against the following interface will then return a session key which can be used for all other interactions.
https://au.itwocx.com/api/latest/api/help/index#!/Login/Login_ByUserToken
Code Sample(s)
Using the session key
Link: https://au.itwocx.com/api/latest/api/help/index
Copy & Paste the session key received from logging in into the api_key field in the top right hand corner and click Explore
Once the page refreshes you can then use any of the interfaces, to for example retrieve a list of Projects.