Partner Organization Creation
Partners can guide their clients to create Uber for Business 3PC organizations using the flow below. Utilizing this flow provides the critical benefit of enabling your integration without additional friction or manual intervention by your client.
Before attempting to utilize this workflow, please work with our Uber for Business partner engineer ing team to assess whether this solution, our Create Organization API, or an alternative solution best suits your needs. You will need to work with Partner Engineering to set up key elements of this flow such as your application’s landing page.
The integration starts with our landing page. The page expects data to be passed using hidden form fields to be able continue with the flow.
The table below gives details of data that needs to be passed.
Key | Type | Description |
---|---|---|
name | string | (Optional) Name of organization to be created |
fname | string | (Optional) First name of Organization Creator |
lname | string | (Optional) Last name of Organization Creator |
string | (Required) Email of Organization Creator | |
countryIso2 | string | (Optional) Country of Organization to be created |
id | string | (Required) Organization’s unique identifier in third party (3P) system. |
hash | string | (Required) For more details on generating hash, review the following below. |
applicationId | string | (Required) Developer application ID created by API partners in Uber developer dashboard. |
¶ Generating Hash and Verification
- Generate a string from the data in the query parameter format.
- The query keys are sorted alphabetically while generating the string.
- The entire string is raw i.e., neither the keys nor the values are encoded in any way.
- Eg: applicationId=<APP_ID>&countryIso2=<COUNTRY_ISO_2>&fname=<CREATOR_FIRST_NAME>&id=<PROVIDER_CLIENT_ORG_ID>&lname=<CREATOR_LAST_NAME>&name=<CLIENT_ORG_NAME>
- The generated string is hashed using the Client Secret.
digester = hmac.new(app_secret, query_param_string, hashlib.sha256)
return digester.hexdigest()
Note To allow for key rotation the signature is generated with primary and secondary keys and the input
¶ Redirecting with correct payload
- Create hidden form and redirect to https://business-integrations.uber.com/connect
const form = document.createElement('form');
form.method = 'POST';
form.action = 'https://business-integrations.uber.com/connect';
const appendHiddenInput = (name, value) => {
const input = document.createElement("input");
input.type = "hidden";
input.name = name;
input.value = value;
form.appendChild(input);
};
appendHiddenInput("query", <INPUT_STRING_FOR_HASH_GENERATION>);
appendHiddenInput("hash", <HASH>);
// Attach the form to the document and submit it
document.body.appendChild(form);
form.submit();