Company API (v2)

Download OpenAPI description
Languages
Servers
Mock server
https://developer.spotnana.com/_mock/openapi/companyapi/
Staging URL
https://apis.spotnana.com/

Companies

APIs to onboard and manage company.

Operations

Create company

Request

This endpoint creates a company. This is allowed only by TMC_ADMIN and above roles.

Bodyapplication/jsonrequired
namestringrequired

Company name

Example: "Spotnana"
emailDomainsArray of stringsunique

List of the company email domains

Example: ["spotnana.com"]
billingCurrencystringrequired

Billing currency of the company

Example: "INR"
phoneNumbersArray of objects(PhoneNumber)

List of company phone numbers

emergencyContactInfosArray of objects(EmergencyContactInfo)

List of company emergency contacts

isSelfSignUpEnabledboolean

Boolean to show if company has self sign up enabled.

Example: true
announcementsArray of objects(Announcement)

Company announcements

companyLogoobject(Image)

An image with meta data. Either the data or url property must be supplied to load the image.

contractedByobject(CompanyId)

Company ID

companyRolesArray of strings(CompanyRole)required

Company roles

Items Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: ["ORG"]
supportConfigsArray of objects(SupportConfig)

Support Configs for company

ccEmailAddressesArray of strings

List of email addresses on which all confirmation emails will be cced. This is applicable only for company roles 'ORG'

Example: ["example@gmail.com"]
bccEmailAddressesArray of strings

List of email addresses on which all confirmation emails will be bcced. This is applicable only for company roles 'ORG'

Example: ["example@gmail.com"]
postalAddressobject(PostalAddress)

Postal Address Details

redirectUrlstring

Redirect URL for the company. It is applicable only for company roles 'PARTNER_TMC'

tmcDefaultConfigurationobject(TmcDefaultConfiguration)

Default TMC configuration.

expensePartnerConfigobject(ExpensePartnerConfig)

Expense Partner Configuration

mobileRedirectUrlstring

Redirect URL for the company for mobile. It is applicable only for company roles 'PARTNER_TMC'

applicableCustomFieldTypesArray of strings(CustomFieldType)

List of custom fields supported by the company.

Items Enum"QUESTION""MEETING""BUDGET""BREX_TOKEN"
oauthPartnerConfigobject(OAuthPartnerConfig)

Config for token exchange in case of partner's have their own IDP.

privacySettingsobject(PrivacySettings)

Privacy settings for a company.

emailClientConfigobject(EmailClientConfig)

Email Client Config

externalIdstring

External id for legal entity.

Example: "company-external-id"
isFakeboolean

Whether the company is a fake company for testing. This is for internal use.

Default false
Example: false
tmcPartnerRoleMappingsArray of objects(TmcPartnerRoleMapping)

list of individual role mappings between spotnana and partner.

loyaltyBlockedCountriesArray of strings

List of 2 letter country codes where business travelers should not be allowed to add loyalty info.

Example: ["US","IN"]
allowDomainBasedAuthConfigboolean

Whether to allow user to get auth config based on email domain

Default false
carbonCostConfigobject(CarbonCostConfig)

The config is used to calculate carbon cost of CO2 emission.

defaultBookingTmcIdobject(CompanyId)

Company ID

supportConfigobject(SupportConfig)Deprecated

Support Configuration for company

rewardsProgramobject(RewardsProgram)Deprecated

Rewards program details.

curl -i -X POST \
  https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Spotnana",
    "emailDomains": [
      "spotnana.com"
    ],
    "billingCurrency": "INR",
    "phoneNumbers": [
      {
        "countryCode": 91,
        "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
        "extension": "222",
        "isoCountryCode": "IN",
        "italianLeadingZero": true,
        "nationalNumber": 8150,
        "numberOfLeadingZeros": 1,
        "preferredDomesticCarrierCode": "7",
        "rawInput": "77777",
        "type": "MOBILE"
      }
    ],
    "emergencyContactInfos": [
      {
        "address": {
          "addressLines": [
            "Golden Gate Bridge"
          ],
          "administrativeArea": "CA",
          "administrativeAreaName": "California",
          "description": "San Francisco Home",
          "isDefault": true,
          "languageCode": "en",
          "locality": "San Francisco",
          "locationCode": "LAX",
          "organization": "Spotnana",
          "postalCode": "94130",
          "continentCode": "AF",
          "recipients": [
            "string"
          ],
          "regionCode": "US",
          "regionName": "America",
          "revision": 1,
          "sortingCode": "Jamaica",
          "sublocality": "string",
          "timezone": "America/Los_Angeles",
          "coordinates": {
            "latitude": 77.1025,
            "longitude": 28.7041
          }
        },
        "designation": "MANAGER",
        "email": "emergency-contact@email.com",
        "name": {
          "family1": "Gandas",
          "family2": "FamilyTwo",
          "given": "Vichitr",
          "middle": "Kumar",
          "suffix": "SR",
          "preferred": "Don"
        },
        "phoneNumber": {
          "countryCode": 91,
          "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
          "extension": "222",
          "isoCountryCode": "IN",
          "italianLeadingZero": true,
          "nationalNumber": 8150,
          "numberOfLeadingZeros": 1,
          "preferredDomesticCarrierCode": "7",
          "rawInput": "77777",
          "type": "MOBILE"
        },
        "userOrgId": {
          "organizationAgencyId": {
            "id": "string"
          },
          "organizationId": {
            "id": "string"
          },
          "userId": {
            "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
          },
          "tmcInfo": {
            "id": {
              "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
            },
            "primaryServiceProviderTmc": {
              "tmcId": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              }
            },
            "secondaryServiceProviderTmcs": [
              {
                "tmcId": {},
                "supplier": "SABRE",
                "travelType": "AIR"
              }
            ],
            "partnerTmcId": {
              "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
            }
          },
          "tmcBasicInfo": {
            "contractingTmc": {
              "id": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              },
              "name": "string",
              "logo": {
                "data": "6935813e12584abda0e43d71cd2ea260",
                "dimensions": {},
                "url": "https://static.wixstatic.com/media/73f2e2_6935813e12584abda0e43d71cd2ea260~mv2.png/v1/fill/w_630,h_94,al_c,q_85,usm_0.66_1.00_0.01/Spotnana%403x.webp"
              }
            },
            "bookingTmc": {
              "id": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              },
              "name": "string",
              "logo": {
                "data": "6935813e12584abda0e43d71cd2ea260",
                "dimensions": {},
                "url": "https://static.wixstatic.com/media/73f2e2_6935813e12584abda0e43d71cd2ea260~mv2.png/v1/fill/w_630,h_94,al_c,q_85,usm_0.66_1.00_0.01/Spotnana%403x.webp"
              }
            }
          }
        }
      }
    ],
    "isSelfSignUpEnabled": true,
    "announcements": [
      {
        "title": "Spotnana on Mission to Unbundle Travel",
        "description": "Amex Ventures Joins Spotnana on Mission to Unbundle Travel.",
        "linkUrl": "https://medium.com/inside-spotnana/amex-ventures-joins-spotnana-on-mission-to-unbundle-travel-3cdb2ecceff4",
        "linkDisplayText": "New announcement"
      }
    ],
    "companyLogo": {
      "data": "6935813e12584abda0e43d71cd2ea260",
      "dimensions": {
        "height": 120,
        "width": 240
      },
      "url": "https://static.wixstatic.com/media/73f2e2_6935813e12584abda0e43d71cd2ea260~mv2.png/v1/fill/w_630,h_94,al_c,q_85,usm_0.66_1.00_0.01/Spotnana%403x.webp"
    },
    "contractedBy": {
      "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
    },
    "companyRoles": [
      "ORG"
    ],
    "supportConfig": {
      "contactNumbers": [
        {
          "countryCode": 91,
          "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
          "extension": "222",
          "isoCountryCode": "IN",
          "italianLeadingZero": true,
          "nationalNumber": 8150,
          "numberOfLeadingZeros": 1,
          "preferredDomesticCarrierCode": "7",
          "rawInput": "77777",
          "type": "MOBILE"
        }
      ],
      "emailAddresses": [
        "support@spotnana.com"
      ],
      "freshdeskConfig": {
        "enabled": true,
        "hasCredentials": false,
        "credentials": {
          "webCredentials": {
            "domain": "string",
            "appId": "string",
            "appKey": "string"
          },
          "mobileCredentials": {
            "domain": "string",
            "appId": "string",
            "appKey": "string"
          }
        }
      },
      "tier": "SEAT1A",
      "genesysConfig": {
        "enabled": true,
        "dataUrl": "string"
      },
      "portalUrls": [
        "www.support.spotnana.com"
      ],
      "zendeskConfig": {
        "enabled": true,
        "integrationId": "1234567890",
        "androidIntegrationId": "1234567890",
        "iosIntegrationId": "1234567890"
      },
      "genesysCloudConfig": {
        "enabled": true,
        "deploymentId": "52dc2a6f-772a-4edf-96d3-b3f0c49400a7",
        "environment": "usa-1",
        "genesysScriptUrl": "https://test.test.com"
      },
      "twilioChatConfig": {
        "enabled": true
      }
    },
    "supportConfigs": [
      {
        "contactNumbers": [
          {
            "countryCode": 91,
            "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
            "extension": "222",
            "isoCountryCode": "IN",
            "italianLeadingZero": true,
            "nationalNumber": 8150,
            "numberOfLeadingZeros": 1,
            "preferredDomesticCarrierCode": "7",
            "rawInput": "77777",
            "type": "MOBILE"
          }
        ],
        "emailAddresses": [
          "support@spotnana.com"
        ],
        "freshdeskConfig": {
          "enabled": true,
          "hasCredentials": false,
          "credentials": {
            "webCredentials": {
              "domain": "string",
              "appId": "string",
              "appKey": "string"
            },
            "mobileCredentials": {
              "domain": "string",
              "appId": "string",
              "appKey": "string"
            }
          }
        },
        "tier": "SEAT1A",
        "genesysConfig": {
          "enabled": true,
          "dataUrl": "string"
        },
        "portalUrls": [
          "www.support.spotnana.com"
        ],
        "zendeskConfig": {
          "enabled": true,
          "integrationId": "1234567890",
          "androidIntegrationId": "1234567890",
          "iosIntegrationId": "1234567890"
        },
        "genesysCloudConfig": {
          "enabled": true,
          "deploymentId": "52dc2a6f-772a-4edf-96d3-b3f0c49400a7",
          "environment": "usa-1",
          "genesysScriptUrl": "https://test.test.com"
        },
        "twilioChatConfig": {
          "enabled": true
        }
      }
    ],
    "ccEmailAddresses": [
      "example@gmail.com"
    ],
    "bccEmailAddresses": [
      "example@gmail.com"
    ],
    "postalAddress": {
      "addressLines": [
        "Golden Gate Bridge"
      ],
      "administrativeArea": "CA",
      "administrativeAreaName": "California",
      "description": "San Francisco Home",
      "isDefault": true,
      "languageCode": "en",
      "locality": "San Francisco",
      "locationCode": "LAX",
      "organization": "Spotnana",
      "postalCode": "94130",
      "continentCode": "AF",
      "recipients": [
        "string"
      ],
      "regionCode": "US",
      "regionName": "America",
      "revision": 1,
      "sortingCode": "Jamaica",
      "sublocality": "string",
      "timezone": "America/Los_Angeles",
      "coordinates": {
        "latitude": 77.1025,
        "longitude": 28.7041
      }
    },
    "redirectUrl": "string",
    "rewardsProgram": {
      "allowedUserRoles": [
        "TRAVEL_ARRANGER"
      ],
      "conversionRate": {
        "currencyCode": "USD",
        "rate": 0.1
      },
      "redeemablePaymentMethods": [
        "BREX_POINTS"
      ],
      "backingCurrency": [
        "USD"
      ]
    },
    "tmcDefaultConfiguration": {
      "defaultBookingTmcId": "734f4ea2-e9ed-4c90-853c-9eed62f1254b",
      "countryWiseBookingTmcs": [
        {
          "countryCode": "US",
          "bookingTmcId": "734f4ea2-e9ed-4c90-853c-9eed62f1254b"
        }
      ]
    },
    "expensePartnerConfig": {
      "partner": "EXPENSIFY",
      "emailConfig": {
        "personalCardConfig": {
          "sendToTraveler": false,
          "personalCardExpenseEmail": "user@company.com"
        },
        "centralCardExpenseEmail": "finance+le@company.com",
        "expensePartnerEmail": "receipts@expensify.com",
        "bccEmail": "docs@company.com"
      },
      "travelType": [
        "AIR"
      ],
      "isExpensePartnerEnabled": true,
      "reportCustomFields": true,
      "personalCardExpenseOwner": {
        "traveler": true,
        "centralEmail": "docs@company.com"
      },
      "centralCardExpenseOwner": {
        "traveler": true,
        "centralEmail": "docs@company.com"
      },
      "partnerReferralId": "1234hgd",
      "itineraryConfig": {
        "skipModificationUpdate": true,
        "skipCancellationUpdate": true
      }
    },
    "mobileRedirectUrl": "string",
    "applicableCustomFieldTypes": [
      "QUESTION"
    ],
    "oauthPartnerConfig": {
      "name": "string",
      "userDetailEndpoint": {
        "url": "string",
        "authHeaderName": "string",
        "userIdentifierType": "PID",
        "responseAttributes": [
          {
            "name": "PID",
            "jsonXpath": "$.user.email"
          }
        ]
      },
      "tokenVerifier": {
        "doVerifyToken": true,
        "type": "OKTA_JWT",
        "verifierDetails": {
          "oktaJwtVerifier": {
            "oauthUrl": "string",
            "audience": "string"
          }
        }
      },
      "doPersistToken": true
    },
    "privacySettings": {
      "allowCompanyAdminAccessToRelativesInfo": true
    },
    "emailClientConfig": {
      "client": "SENDGRID",
      "credentials": {
        "emailClientSecretKey": {
          "secretKey": "SECRET_KEY",
          "versionId": "1"
        }
      },
      "defaultSenderAddress": "test@somedomain.com",
      "defaultSenderName": "Test Sender"
    },
    "externalId": "company-external-id",
    "isFake": false,
    "tmcPartnerRoleMappings": [
      {
        "partnerRole": "string",
        "spotnanaRole": "TRAVEL_ARRANGER"
      }
    ],
    "loyaltyBlockedCountries": [
      "US",
      "IN"
    ],
    "allowDomainBasedAuthConfig": false,
    "carbonCostConfig": {
      "price": {
        "amount": 510,
        "currencyCode": "GBP",
        "convertedAmount": 715.42,
        "convertedCurrency": "USD",
        "otherCoinage": [
          {
            "coinageCode": "BREX_POINTS",
            "amount": 1000,
            "conversionRate": 0.01,
            "preferredCurrencyConversionRate": 0.01
          }
        ]
      },
      "weight": {
        "weight": 150,
        "unit": "KG"
      }
    },
    "defaultBookingTmcId": {
      "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
    }
  }'

Responses

Created

Bodyapplication/json
idstring(uuid)required
Response
application/json
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08" }

List companies

Request

This endpoint lists companies. If externalId is provided in query param, only the company having the specified external ID is returned.

Query
externalIdstring

External id of the entity.

Example: externalId=my-external-id
companyRolestring(CompanyRole)

Filter by a particular role

Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: companyRole=ORG
companyIdsArray of strings(uuid)

Filter by a list of companies

curl -i -X GET \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies?companyIds=497f6eca-6276-4993-bfeb-53cbbbba6f08&companyRole=ORG&externalId=string' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
lengthinteger(int32)
elementsArray of objects(Reference object containing uuid and name of the entity.)

List of references containing id and name.

Response
application/json
{ "length": 0, "elements": [ {} ] }

Get company

Request

This endpoint gets a company by ID.

Path
companyIdstringrequired

Identifier for company. External id can be supplied in X prefixed form. For instance, if external_id = abc, then Xabc, has to be passed.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Headers
x-application-idstring(uuid)
Example: 4974a66b-7493-4f41-908c-58ba81093947
curl -i -X GET \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'x-application-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08'

Responses

OK

Bodyapplication/json
idobject(CompanyId)required

Company ID

id.​idstring(uuid)required
Example: "f49d00fe-1eda-4304-ba79-a980f565281d"
namestringrequired

Company name

Example: "Spotnana"
emailDomainsArray of stringsunique

List of the company email domains

Example: ["spotnana.com"]
billingCurrencystringrequired

Billing currency of the company

Example: "INR"
phoneNumbersArray of objects(PhoneNumber)

List of company phone numbers

emergencyContactInfosArray of objects(EmergencyContactInfo)

List of company emergency contacts

isSelfSignUpEnabledboolean

Boolean to show if company has self sign up enabled.

Example: true
announcementsArray of objects(Announcement)

Company announcements

companyLogoobject(Image)

An image with meta data. Either the data or url property must be supplied to load the image.

contractedByobject(CompanyId)

Company ID

isActiveboolean

Boolean to show if this is an active company.

companyRolesArray of strings(CompanyRole)required

Company roles

Items Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: ["ORG"]
ccEmailAddressesArray of strings

List of email addresses on which all confirmation emails will be cced. This is applicable only for company roles 'ORG'

Example: ["example@gmail.com"]
bccEmailAddressesArray of strings

List of email addresses on which all confirmation emails will be bcced. This is applicable only for company roles 'ORG'

Example: ["example@gmail.com"]
connectorsArray of objects(Connector)

Connectors related to company.

postalAddressobject(PostalAddress)

Postal Address Details

redirectUrlstring

Redirect URL for the company. It is applicable only for company roles 'PARTNER_TMC'

tmcDefaultConfigurationobject(TmcDefaultConfiguration)

Default TMC configuration.

expensePartnerConfigobject(ExpensePartnerConfig)

Expense Partner Configuration

mobileRedirectUrlstring

Redirect URL for the company for mobile. It is applicable only for company roles 'PARTNER_TMC'

applicableCustomFieldTypesArray of strings(CustomFieldType)

List of custom fields supported by the company.

Items Enum"QUESTION""MEETING""BUDGET""BREX_TOKEN"
oauthPartnerConfigobject(OAuthPartnerConfig)

Config for token exchange in case of partner's have their own IDP.

privacySettingsobject(PrivacySettings)

Privacy settings for a company.

designationTreeobject(DesignationNode)

Designation tree for company showing who reports whom.

externalIdstring

External id to be linked with this.

Example: "MyCompanyId"
emailClientConfigobject(EmailClientConfig)

Email Client Config

isFakeboolean

Whether the company is a fake company for testing. This is for internal use.

Default false
Example: false
tmcPartnerRoleMappingsArray of objects(TmcPartnerRoleMapping)

list of individual role mappings between spotnana and partner.

supportConfigsobject(SupportConfigs)
loyaltyBlockedCountriesArray of strings

List of 2 letter country codes where business travelers should not be allowed to add loyalty info.

Example: ["US","IN"]
allowDomainBasedAuthConfigboolean

Whether to allow user to get auth config based on email domain

Default false
carbonCostConfigobject(CarbonCostConfig)

The config is used to calculate carbon cost of CO2 emission.

defaultBookingTmcIdobject(CompanyId)

Company ID

supportConfigobject(SupportConfig)Deprecated

Support Configuration for company

rewardsProgramobject(RewardsProgram)Deprecated

Rewards program details.

Response
application/json
{ "id": { "id": "f49d00fe-1eda-4304-ba79-a980f565281d" }, "name": "Spotnana", "emailDomains": [ "spotnana.com" ], "billingCurrency": "INR", "phoneNumbers": [ {} ], "emergencyContactInfos": [ {} ], "isSelfSignUpEnabled": true, "announcements": [ {} ], "companyLogo": { "data": "6935813e12584abda0e43d71cd2ea260", "dimensions": {}, "url": "https://static.wixstatic.com/media/73f2e2_6935813e12584abda0e43d71cd2ea260~mv2.png/v1/fill/w_630,h_94,al_c,q_85,usm_0.66_1.00_0.01/Spotnana%403x.webp" }, "contractedBy": { "id": "f49d00fe-1eda-4304-ba79-a980f565281d" }, "isActive": true, "companyRoles": [ "ORG" ], "supportConfig": { "contactNumbers": [], "emailAddresses": [], "freshdeskConfig": {}, "tier": "SEAT1A", "genesysConfig": {}, "portalUrls": [], "zendeskConfig": {}, "genesysCloudConfig": {}, "twilioChatConfig": {} }, "ccEmailAddresses": [ "example@gmail.com" ], "bccEmailAddresses": [ "example@gmail.com" ], "connectors": [ {} ], "postalAddress": { "addressLines": [], "administrativeArea": "CA", "administrativeAreaName": "California", "description": "San Francisco Home", "isDefault": true, "languageCode": "en", "locality": "San Francisco", "locationCode": "LAX", "organization": "Spotnana", "postalCode": "94130", "continentCode": "AF", "recipients": [], "regionCode": "US", "regionName": "America", "revision": 1, "sortingCode": "Jamaica", "sublocality": "string", "timezone": "America/Los_Angeles", "coordinates": {} }, "redirectUrl": "string", "rewardsProgram": { "allowedUserRoles": [], "conversionRate": {}, "redeemablePaymentMethods": [], "backingCurrency": [] }, "tmcDefaultConfiguration": { "defaultBookingTmcId": "734f4ea2-e9ed-4c90-853c-9eed62f1254b", "countryWiseBookingTmcs": [] }, "expensePartnerConfig": { "partner": "EXPENSIFY", "emailConfig": {}, "travelType": [], "isExpensePartnerEnabled": true, "reportCustomFields": true, "personalCardExpenseOwner": {}, "centralCardExpenseOwner": {}, "partnerReferralId": "1234hgd", "itineraryConfig": {} }, "mobileRedirectUrl": "string", "applicableCustomFieldTypes": [ "QUESTION" ], "oauthPartnerConfig": { "name": "string", "userDetailEndpoint": {}, "tokenVerifier": {}, "doPersistToken": true }, "privacySettings": { "allowCompanyAdminAccessToRelativesInfo": true }, "designationTree": { "name": "string", "children": [] }, "externalId": "MyCompanyId", "emailClientConfig": { "client": "SENDGRID", "credentials": {}, "defaultSenderAddress": "test@somedomain.com", "defaultSenderName": "Test Sender" }, "isFake": false, "tmcPartnerRoleMappings": [ {} ], "supportConfigs": { "length": 0, "elements": [] }, "loyaltyBlockedCountries": [ "US", "IN" ], "allowDomainBasedAuthConfig": false, "carbonCostConfig": { "price": {}, "weight": {} }, "defaultBookingTmcId": { "id": "f49d00fe-1eda-4304-ba79-a980f565281d" } }

Update company

Request

This endpoint updates a company by ID.

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Bodyapplication/jsonrequired
idobject(CompanyId)required

Company ID

id.​idstring(uuid)required
Example: "f49d00fe-1eda-4304-ba79-a980f565281d"
namestringrequired

Company name

Example: "Spotnana"
emailDomainsArray of stringsunique

List of the company email domains

Example: ["spotnana.com"]
billingCurrencystringrequired

Billing currency of the company

Example: "INR"
phoneNumbersArray of objects(PhoneNumber)

List of company phone numbers

emergencyContactInfosArray of objects(EmergencyContactInfo)

List of company emergency contacts

isSelfSignUpEnabledboolean

Boolean to show if company has self sign up enabled.

Example: true
announcementsArray of objects(Announcement)

Company announcements

companyLogoobject(Image)

An image with meta data. Either the data or url property must be supplied to load the image.

contractedByobject(CompanyId)

Company ID

isActiveboolean

Boolean to show if this is an active company.

companyRolesArray of strings(CompanyRole)required

Company roles

Items Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: ["ORG"]
ccEmailAddressesArray of strings

List of email addresses on which all confirmation emails will be cced. This is applicable only for company roles 'ORG'

Example: ["example@gmail.com"]
bccEmailAddressesArray of strings

List of email addresses on which all confirmation emails will be bcced. This is applicable only for company roles 'ORG'

Example: ["example@gmail.com"]
connectorsArray of objects(Connector)

Connectors related to company.

postalAddressobject(PostalAddress)

Postal Address Details

redirectUrlstring

Redirect URL for the company. It is applicable only for company roles 'PARTNER_TMC'

tmcDefaultConfigurationobject(TmcDefaultConfiguration)

Default TMC configuration.

expensePartnerConfigobject(ExpensePartnerConfig)

Expense Partner Configuration

mobileRedirectUrlstring

Redirect URL for the company for mobile. It is applicable only for company roles 'PARTNER_TMC'

applicableCustomFieldTypesArray of strings(CustomFieldType)

List of custom fields supported by the company.

Items Enum"QUESTION""MEETING""BUDGET""BREX_TOKEN"
oauthPartnerConfigobject(OAuthPartnerConfig)

Config for token exchange in case of partner's have their own IDP.

privacySettingsobject(PrivacySettings)

Privacy settings for a company.

designationTreeobject(DesignationNode)

Designation tree for company showing who reports whom.

externalIdstring

External id to be linked with this.

Example: "MyCompanyId"
emailClientConfigobject(EmailClientConfig)

Email Client Config

isFakeboolean

Whether the company is a fake company for testing. This is for internal use.

Default false
Example: false
tmcPartnerRoleMappingsArray of objects(TmcPartnerRoleMapping)

list of individual role mappings between spotnana and partner.

supportConfigsobject(SupportConfigs)
loyaltyBlockedCountriesArray of strings

List of 2 letter country codes where business travelers should not be allowed to add loyalty info.

Example: ["US","IN"]
allowDomainBasedAuthConfigboolean

Whether to allow user to get auth config based on email domain

Default false
carbonCostConfigobject(CarbonCostConfig)

The config is used to calculate carbon cost of CO2 emission.

defaultBookingTmcIdobject(CompanyId)

Company ID

supportConfigobject(SupportConfig)Deprecated

Support Configuration for company

rewardsProgramobject(RewardsProgram)Deprecated

Rewards program details.

curl -i -X PUT \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "id": {
      "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
    },
    "name": "Spotnana",
    "emailDomains": [
      "spotnana.com"
    ],
    "billingCurrency": "INR",
    "phoneNumbers": [
      {
        "countryCode": 91,
        "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
        "extension": "222",
        "isoCountryCode": "IN",
        "italianLeadingZero": true,
        "nationalNumber": 8150,
        "numberOfLeadingZeros": 1,
        "preferredDomesticCarrierCode": "7",
        "rawInput": "77777",
        "type": "MOBILE"
      }
    ],
    "emergencyContactInfos": [
      {
        "address": {
          "addressLines": [
            "Golden Gate Bridge"
          ],
          "administrativeArea": "CA",
          "administrativeAreaName": "California",
          "description": "San Francisco Home",
          "isDefault": true,
          "languageCode": "en",
          "locality": "San Francisco",
          "locationCode": "LAX",
          "organization": "Spotnana",
          "postalCode": "94130",
          "continentCode": "AF",
          "recipients": [
            "string"
          ],
          "regionCode": "US",
          "regionName": "America",
          "revision": 1,
          "sortingCode": "Jamaica",
          "sublocality": "string",
          "timezone": "America/Los_Angeles",
          "coordinates": {
            "latitude": 77.1025,
            "longitude": 28.7041
          }
        },
        "designation": "MANAGER",
        "email": "emergency-contact@email.com",
        "name": {
          "family1": "Gandas",
          "family2": "FamilyTwo",
          "given": "Vichitr",
          "middle": "Kumar",
          "suffix": "SR",
          "preferred": "Don"
        },
        "phoneNumber": {
          "countryCode": 91,
          "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
          "extension": "222",
          "isoCountryCode": "IN",
          "italianLeadingZero": true,
          "nationalNumber": 8150,
          "numberOfLeadingZeros": 1,
          "preferredDomesticCarrierCode": "7",
          "rawInput": "77777",
          "type": "MOBILE"
        },
        "userOrgId": {
          "organizationAgencyId": {
            "id": "string"
          },
          "organizationId": {
            "id": "string"
          },
          "userId": {
            "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
          },
          "tmcInfo": {
            "id": {
              "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
            },
            "primaryServiceProviderTmc": {
              "tmcId": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              }
            },
            "secondaryServiceProviderTmcs": [
              {
                "tmcId": {},
                "supplier": "SABRE",
                "travelType": "AIR"
              }
            ],
            "partnerTmcId": {
              "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
            }
          },
          "tmcBasicInfo": {
            "contractingTmc": {
              "id": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              },
              "name": "string",
              "logo": {
                "data": "6935813e12584abda0e43d71cd2ea260",
                "dimensions": {},
                "url": "https://static.wixstatic.com/media/73f2e2_6935813e12584abda0e43d71cd2ea260~mv2.png/v1/fill/w_630,h_94,al_c,q_85,usm_0.66_1.00_0.01/Spotnana%403x.webp"
              }
            },
            "bookingTmc": {
              "id": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              },
              "name": "string",
              "logo": {
                "data": "6935813e12584abda0e43d71cd2ea260",
                "dimensions": {},
                "url": "https://static.wixstatic.com/media/73f2e2_6935813e12584abda0e43d71cd2ea260~mv2.png/v1/fill/w_630,h_94,al_c,q_85,usm_0.66_1.00_0.01/Spotnana%403x.webp"
              }
            }
          }
        }
      }
    ],
    "isSelfSignUpEnabled": true,
    "announcements": [
      {
        "title": "Spotnana on Mission to Unbundle Travel",
        "description": "Amex Ventures Joins Spotnana on Mission to Unbundle Travel.",
        "linkUrl": "https://medium.com/inside-spotnana/amex-ventures-joins-spotnana-on-mission-to-unbundle-travel-3cdb2ecceff4",
        "linkDisplayText": "New announcement"
      }
    ],
    "companyLogo": {
      "data": "6935813e12584abda0e43d71cd2ea260",
      "dimensions": {
        "height": 120,
        "width": 240
      },
      "url": "https://static.wixstatic.com/media/73f2e2_6935813e12584abda0e43d71cd2ea260~mv2.png/v1/fill/w_630,h_94,al_c,q_85,usm_0.66_1.00_0.01/Spotnana%403x.webp"
    },
    "contractedBy": {
      "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
    },
    "isActive": true,
    "companyRoles": [
      "ORG"
    ],
    "supportConfig": {
      "contactNumbers": [
        {
          "countryCode": 91,
          "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
          "extension": "222",
          "isoCountryCode": "IN",
          "italianLeadingZero": true,
          "nationalNumber": 8150,
          "numberOfLeadingZeros": 1,
          "preferredDomesticCarrierCode": "7",
          "rawInput": "77777",
          "type": "MOBILE"
        }
      ],
      "emailAddresses": [
        "support@spotnana.com"
      ],
      "freshdeskConfig": {
        "enabled": true,
        "hasCredentials": false,
        "credentials": {
          "webCredentials": {
            "domain": "string",
            "appId": "string",
            "appKey": "string"
          },
          "mobileCredentials": {
            "domain": "string",
            "appId": "string",
            "appKey": "string"
          }
        }
      },
      "tier": "SEAT1A",
      "genesysConfig": {
        "enabled": true,
        "dataUrl": "string"
      },
      "portalUrls": [
        "www.support.spotnana.com"
      ],
      "zendeskConfig": {
        "enabled": true,
        "integrationId": "1234567890",
        "androidIntegrationId": "1234567890",
        "iosIntegrationId": "1234567890"
      },
      "genesysCloudConfig": {
        "enabled": true,
        "deploymentId": "52dc2a6f-772a-4edf-96d3-b3f0c49400a7",
        "environment": "usa-1",
        "genesysScriptUrl": "https://test.test.com"
      },
      "twilioChatConfig": {
        "enabled": true
      }
    },
    "ccEmailAddresses": [
      "example@gmail.com"
    ],
    "bccEmailAddresses": [
      "example@gmail.com"
    ],
    "connectors": [
      {
        "connectorType": "HR_FEED_CONNECTOR",
        "connectorId": {
          "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
        }
      }
    ],
    "postalAddress": {
      "addressLines": [
        "Golden Gate Bridge"
      ],
      "administrativeArea": "CA",
      "administrativeAreaName": "California",
      "description": "San Francisco Home",
      "isDefault": true,
      "languageCode": "en",
      "locality": "San Francisco",
      "locationCode": "LAX",
      "organization": "Spotnana",
      "postalCode": "94130",
      "continentCode": "AF",
      "recipients": [
        "string"
      ],
      "regionCode": "US",
      "regionName": "America",
      "revision": 1,
      "sortingCode": "Jamaica",
      "sublocality": "string",
      "timezone": "America/Los_Angeles",
      "coordinates": {
        "latitude": 77.1025,
        "longitude": 28.7041
      }
    },
    "redirectUrl": "string",
    "rewardsProgram": {
      "allowedUserRoles": [
        "TRAVEL_ARRANGER"
      ],
      "conversionRate": {
        "currencyCode": "USD",
        "rate": 0.1
      },
      "redeemablePaymentMethods": [
        "BREX_POINTS"
      ],
      "backingCurrency": [
        "USD"
      ]
    },
    "tmcDefaultConfiguration": {
      "defaultBookingTmcId": "734f4ea2-e9ed-4c90-853c-9eed62f1254b",
      "countryWiseBookingTmcs": [
        {
          "countryCode": "US",
          "bookingTmcId": "734f4ea2-e9ed-4c90-853c-9eed62f1254b"
        }
      ]
    },
    "expensePartnerConfig": {
      "partner": "EXPENSIFY",
      "emailConfig": {
        "personalCardConfig": {
          "sendToTraveler": false,
          "personalCardExpenseEmail": "user@company.com"
        },
        "centralCardExpenseEmail": "finance+le@company.com",
        "expensePartnerEmail": "receipts@expensify.com",
        "bccEmail": "docs@company.com"
      },
      "travelType": [
        "AIR"
      ],
      "isExpensePartnerEnabled": true,
      "reportCustomFields": true,
      "personalCardExpenseOwner": {
        "traveler": true,
        "centralEmail": "docs@company.com"
      },
      "centralCardExpenseOwner": {
        "traveler": true,
        "centralEmail": "docs@company.com"
      },
      "partnerReferralId": "1234hgd",
      "itineraryConfig": {
        "skipModificationUpdate": true,
        "skipCancellationUpdate": true
      }
    },
    "mobileRedirectUrl": "string",
    "applicableCustomFieldTypes": [
      "QUESTION"
    ],
    "oauthPartnerConfig": {
      "name": "string",
      "userDetailEndpoint": {
        "url": "string",
        "authHeaderName": "string",
        "userIdentifierType": "PID",
        "responseAttributes": [
          {
            "name": "PID",
            "jsonXpath": "$.user.email"
          }
        ]
      },
      "tokenVerifier": {
        "doVerifyToken": true,
        "type": "OKTA_JWT",
        "verifierDetails": {
          "oktaJwtVerifier": {
            "oauthUrl": "string",
            "audience": "string"
          }
        }
      },
      "doPersistToken": true
    },
    "privacySettings": {
      "allowCompanyAdminAccessToRelativesInfo": true
    },
    "designationTree": {
      "name": "string",
      "children": [
        {}
      ]
    },
    "externalId": "MyCompanyId",
    "emailClientConfig": {
      "client": "SENDGRID",
      "credentials": {
        "emailClientSecretKey": {
          "secretKey": "SECRET_KEY",
          "versionId": "1"
        }
      },
      "defaultSenderAddress": "test@somedomain.com",
      "defaultSenderName": "Test Sender"
    },
    "isFake": false,
    "tmcPartnerRoleMappings": [
      {
        "partnerRole": "string",
        "spotnanaRole": "TRAVEL_ARRANGER"
      }
    ],
    "supportConfigs": {
      "length": 0,
      "elements": [
        {
          "contactNumbers": [
            {
              "countryCode": 91,
              "countryCodeSource": "FROM_NUMBER_WITH_PLUS_SIGN",
              "extension": "222",
              "isoCountryCode": "IN",
              "italianLeadingZero": true,
              "nationalNumber": 8150,
              "numberOfLeadingZeros": 1,
              "preferredDomesticCarrierCode": "7",
              "rawInput": "77777",
              "type": "MOBILE"
            }
          ],
          "emailAddresses": [
            "support@spotnana.com"
          ],
          "freshdeskConfig": {
            "enabled": true,
            "hasCredentials": false,
            "credentials": {
              "webCredentials": {
                "domain": "string",
                "appId": "string",
                "appKey": "string"
              },
              "mobileCredentials": {
                "domain": "string",
                "appId": "string",
                "appKey": "string"
              }
            }
          },
          "tier": "SEAT1A",
          "genesysConfig": {
            "enabled": true,
            "dataUrl": "string"
          },
          "portalUrls": [
            "www.support.spotnana.com"
          ],
          "zendeskConfig": {
            "enabled": true,
            "integrationId": "1234567890",
            "androidIntegrationId": "1234567890",
            "iosIntegrationId": "1234567890"
          },
          "genesysCloudConfig": {
            "enabled": true,
            "deploymentId": "52dc2a6f-772a-4edf-96d3-b3f0c49400a7",
            "environment": "usa-1",
            "genesysScriptUrl": "https://test.test.com"
          },
          "twilioChatConfig": {
            "enabled": true
          }
        }
      ]
    },
    "loyaltyBlockedCountries": [
      "US",
      "IN"
    ],
    "allowDomainBasedAuthConfig": false,
    "carbonCostConfig": {
      "price": {
        "amount": 510,
        "currencyCode": "GBP",
        "convertedAmount": 715.42,
        "convertedCurrency": "USD",
        "otherCoinage": [
          {
            "coinageCode": "BREX_POINTS",
            "amount": 1000,
            "conversionRate": 0.01,
            "preferredCurrencyConversionRate": 0.01
          }
        ]
      },
      "weight": {
        "weight": 150,
        "unit": "KG"
      }
    },
    "defaultBookingTmcId": {
      "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
    }
  }'

Responses

Updated Successfully

Response
application/json
{ "debugIdentifier": "string", "errorMessages": [ {} ] }

Delete company

Request

This endpoint deletes a company by ID.

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
curl -i -X DELETE \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

Deleted Successfully

Response
application/json
{ "debugIdentifier": "string", "errorMessages": [ {} ] }

Get company features

Request

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Query
companyRolestring(CompanyRole)

Role of the company.

Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: companyRole=TMC
Headers
X-Application-Idstring(uuid)
Example: 4974a66b-7493-4f41-908c-58ba81093947
curl -i -X GET \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/features?companyRole=ORG' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'X-Application-Id: 497f6eca-6276-4993-bfeb-53cbbbba6f08'

Responses

OK

Bodyapplication/json
lengthinteger

Number of features.

Example: 1
featuresArray of objects(FeatureConfig)

Features related to company.

Response
application/json
{ "length": 1, "features": [ {} ] }

Update Company Features

Request

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Query
companyRolestring(CompanyRole)

Role of the company.

Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: companyRole=TMC
Headers
X-Application-Idstring(uuid)
Example: 4974a66b-7493-4f41-908c-58ba81093947
Bodyapplication/jsonrequired
featuresToUpdateArray of objects(FeatureConfig)

Features that has to be updated.

featuresToDeleteArray of strings(FeatureNameEnum)

Features that has to be deleted.

Items Enum"FLIGHT_RESULTS_OOP""HOTEL_RESULTS_OOP""RAIL_RESULTS_OOP""CARS_RESULTS_OOP""PAYMENT_ADD_CARD""MENU_ITEM_POLICIES""INTEGRATION_EXPENSIFY""TRAVELER_SELECTION""FEATURE_PERSONAL_TRAVEL""PRODUCT_OBT_RAIL"
Example: ["ADMIN_VIRTUAL_CARD"]
curl -i -X PATCH \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/features?companyRole=ORG' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'X-Application-Id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
  -d '{
    "featuresToUpdate": [
      {
        "name": "ADMIN_VIRTUAL_CARD",
        "value": "string"
      }
    ],
    "featuresToDelete": [
      "ADMIN_VIRTUAL_CARD"
    ]
  }'

Responses

OK

Response
application/json
{ "debugIdentifier": "string", "errorMessages": [ {} ] }

Get company travel content config

Request

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
curl -i -X GET \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/travel-content-config' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
airConfigobject(AirConfig)

Air content config

Response
application/json
{ "airConfig": { "fareCategoryFilter": [] } }

Update company travel content config

Request

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Bodyapplication/jsonrequired

Travel content config of a given company

airConfigobject(AirConfig)

Air content config

curl -i -X PUT \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/travel-content-config' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "airConfig": {
      "fareCategoryFilter": [
        {
          "priority": 1,
          "origin": {
            "value": "string",
            "metadata": {
              "type": "CITY",
              "code": "string"
            },
            "infos": [
              {}
            ]
          },
          "destination": {
            "value": "string",
            "metadata": {
              "type": "CITY",
              "code": "string"
            },
            "infos": [
              {}
            ]
          },
          "fareCategoryOption": [
            {
              "fareCategory": {
                "ngsCategory": "UNKNOWN_NGS_CATEGORY",
                "cabinViewCategory": "UNKNOWN_CABIN_CATEGORY"
              },
              "disabled": true
            }
          ]
        }
      ]
    }
  }'

Responses

OK

Response
application/json
{ "debugIdentifier": "string", "errorMessages": [ {} ] }

Delete company travel content config

Request

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
curl -i -X DELETE \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/travel-content-config' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Response
application/json
{ "debugIdentifier": "string", "errorMessages": [ {} ] }

Updates white label config

Request

This endpoint stores white label config for the company at different entity levels.

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Query
companyRolestring(CompanyRole)required

Role of the company.

Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: companyRole=ORG
Bodyapplication/jsonrequired
companyNamestring
Example: "Spotnana"
colorsobject(ColorWhiteLabelConfig)required

Whitelabel configuration related to colours.

colors.​primarystring
Example: "#D33B47"
colors.​primaryDarkstring
Example: "#D33B47"
colors.​primaryLightstring
Example: "#D33B47"
colors.​primaryPalestring
Example: "#D33B47"
colors.​onPrimarystring
Example: "#D33B47"
colors.​secondarystring
Example: "#D33B47"
colors.​secondaryDarkstring
Example: "#D33B47"
colors.​secondaryLightstring
Example: "#D33B47"
colors.​secondaryPalestring
Example: "#D33B47"
colors.​onSecondarystring
Example: "#D33B47"
colors.​errorstring
Example: "#D33B47"
colors.​errorDarkstring
Example: "#D33B47"
colors.​errorLightstring
Example: "#D33B47"
colors.​errorPalestring
Example: "#D33B47"
colors.​onErrorstring
Example: "#D33B47"
webLinksobject(WebLinksConfig)

Weblinks which are parts of WhiteLabelConfig.

fromEmailAddressstring
Example: "no-reply@spotnana.com"
fontFamilystring
Default "Arial"
Example: "Arial"
emailFontFamilystring
Default "Roboto"
Example: "Roboto"
fontFamilyCssstring
Example: "https://duploservices-stage-email-assets-873909615026.s3.us-west-2.amazonaws.com/partners/amazon/emberDisplay.css"
emailClientConfigobject(EmailClientConfig)

Email Client Config

clientRoutingBasePathstring

Base path used by Spotnana OBT application to invoke API calls. Default path value is /

routingConfigobject(RoutingConfig)

App routing configuration.

privacyDisclaimerobject(PrivacyDisclaimer)

Html to shown on the the login page. This will be text with hyper links.

curl -i -X PUT \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/white-label-config?companyRole=ORG' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "companyName": "Spotnana",
    "colors": {
      "primary": "#D33B47",
      "primaryDark": "#D33B47",
      "primaryLight": "#D33B47",
      "primaryPale": "#D33B47",
      "onPrimary": "#D33B47",
      "secondary": "#D33B47",
      "secondaryDark": "#D33B47",
      "secondaryLight": "#D33B47",
      "secondaryPale": "#D33B47",
      "onSecondary": "#D33B47",
      "error": "#D33B47",
      "errorDark": "#D33B47",
      "errorLight": "#D33B47",
      "errorPale": "#D33B47",
      "onError": "#D33B47"
    },
    "webLinks": {
      "logoHeader": "https://duploservices-stage-email-assets-873909615026.s3.us-west-2.amazonaws.com/confirmation/spotnana3.png",
      "logoFooter": "https://duploservices-stage-email-assets-873909615026.s3-us-west-2.amazonaws.com/approval/spotnana-s-logo.png",
      "companyWebsiteAddress": "https://www.spotnana.com",
      "homePage": "https://stage-app.spotnana.com/flights",
      "itineraryPage": "https://stage-app.spotnana.com/trips/3375488451",
      "disclaimerPage": "https://www.spotnana.com/terms",
      "privacyPage": "https://www.spotnana.com/privacy-policy",
      "hardApprovalUrl": "https://stage-app.spotnana.com/hardapproval?approvalId=CgozMzQ5OTI4MzI2EiMKIQoMCgpQaWh1IEd1cHRhEhFwaWh1QHNwb3RuYW5hLmNvbQ%3D%3D&approverName=Pihu%20Gupta&travelerName=Pihu%20Gupta&tripName=TESting%201&tripId=2418132231&voidDate=Tuesday,%2021%20Jun%20at%2002:00%20UTC",
      "itineraryFlightStatsUrl": "https://stage-app.spotnana.com/trips/4694735622",
      "appEmbedScriptUrl": "https://customjs.partner.com",
      "logoNavigationLink": "http://www.spotnana.com",
      "illustration": "https://duploservices-stage-email-assets-873909615026.s3-us-west-2.amazonaws.com/approval/spotnana-s-logo.png",
      "poweredBySpotnana": false,
      "logoutRedirectUrl": "https://www.spotnana.com/signout",
      "faviconUrl": "http://www.spotnana.com",
      "appDownloadLinks": {
        "androidPlayStoreUrl": "https://play.google.com/store/apps/details?id=com.spotnana",
        "iosAppStoreUrl": "https://apps.apple.com/in/app/spotnana-travel-booking/id1580021446",
        "qrCodeUrl": "https://www.spotnana.com"
      },
      "socialMediaLinks": {
        "facebookUrl": "https://www.facebook.com/spotnanaofficial",
        "twitterUrl": "https://twitter.com/spotnana",
        "instagramUrl": "https://www.instagram.com/spotnana_official"
      },
      "termsOfUse": "https://www.spotnana.com/terms/",
      "illustrationActionUrl": "https://www.spotnana.com/login"
    },
    "fromEmailAddress": "no-reply@spotnana.com",
    "fontFamily": "Arial",
    "emailFontFamily": "Roboto",
    "fontFamilyCss": "https://duploservices-stage-email-assets-873909615026.s3.us-west-2.amazonaws.com/partners/amazon/emberDisplay.css",
    "emailClientConfig": {
      "client": "SENDGRID",
      "credentials": {
        "emailClientSecretKey": {
          "secretKey": "SECRET_KEY",
          "versionId": "1"
        }
      },
      "defaultSenderAddress": "test@somedomain.com",
      "defaultSenderName": "Test Sender"
    },
    "clientRoutingBasePath": "string",
    "routingConfig": {
      "appHomeRoute": "/my-account"
    },
    "privacyDisclaimer": {
      "show": true,
      "html": "</html>"
    }
  }'

Responses

OK

Response
application/json
{ "debugIdentifier": "string", "errorMessages": [ {} ] }

Get white label config

Request

This endpoint fetches the white label config for the company.

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Query
companyRolestring(CompanyRole)required

Role of the company.

Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: companyRole=ORG
applicationIdstring(uuid)

Application context to get white label config.

Example: applicationId=1234a66b-7493-4f41-908c-58ba81055667
curl -i -X GET \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/white-label-config?applicationId=497f6eca-6276-4993-bfeb-53cbbbba6f08&companyRole=ORG' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
companyNamestring
Example: "Spotnana"
colorsobject(ColorWhiteLabelConfig)required

Whitelabel configuration related to colours.

colors.​primarystring
Example: "#D33B47"
colors.​primaryDarkstring
Example: "#D33B47"
colors.​primaryLightstring
Example: "#D33B47"
colors.​primaryPalestring
Example: "#D33B47"
colors.​onPrimarystring
Example: "#D33B47"
colors.​secondarystring
Example: "#D33B47"
colors.​secondaryDarkstring
Example: "#D33B47"
colors.​secondaryLightstring
Example: "#D33B47"
colors.​secondaryPalestring
Example: "#D33B47"
colors.​onSecondarystring
Example: "#D33B47"
colors.​errorstring
Example: "#D33B47"
colors.​errorDarkstring
Example: "#D33B47"
colors.​errorLightstring
Example: "#D33B47"
colors.​errorPalestring
Example: "#D33B47"
colors.​onErrorstring
Example: "#D33B47"
webLinksobject(WebLinksConfig)

Weblinks which are parts of WhiteLabelConfig.

fromEmailAddressstring
Example: "no-reply@spotnana.com"
fontFamilystring
Default "Arial"
Example: "Arial"
emailFontFamilystring
Default "Roboto"
Example: "Roboto"
fontFamilyCssstring
Example: "https://duploservices-stage-email-assets-873909615026.s3.us-west-2.amazonaws.com/partners/amazon/emberDisplay.css"
emailClientConfigobject(EmailClientConfig)

Email Client Config

clientRoutingBasePathstring

Base path used by Spotnana OBT application to invoke API calls. Default path value is /

routingConfigobject(RoutingConfig)

App routing configuration.

privacyDisclaimerobject(PrivacyDisclaimer)

Html to shown on the the login page. This will be text with hyper links.

Response
application/json
{ "companyName": "Spotnana", "colors": { "primary": "#D33B47", "primaryDark": "#D33B47", "primaryLight": "#D33B47", "primaryPale": "#D33B47", "onPrimary": "#D33B47", "secondary": "#D33B47", "secondaryDark": "#D33B47", "secondaryLight": "#D33B47", "secondaryPale": "#D33B47", "onSecondary": "#D33B47", "error": "#D33B47", "errorDark": "#D33B47", "errorLight": "#D33B47", "errorPale": "#D33B47", "onError": "#D33B47" }, "webLinks": { "logoHeader": "https://duploservices-stage-email-assets-873909615026.s3.us-west-2.amazonaws.com/confirmation/spotnana3.png", "logoFooter": "https://duploservices-stage-email-assets-873909615026.s3-us-west-2.amazonaws.com/approval/spotnana-s-logo.png", "companyWebsiteAddress": "https://www.spotnana.com", "homePage": "https://stage-app.spotnana.com/flights", "itineraryPage": "https://stage-app.spotnana.com/trips/3375488451", "disclaimerPage": "https://www.spotnana.com/terms", "privacyPage": "https://www.spotnana.com/privacy-policy", "hardApprovalUrl": "https://stage-app.spotnana.com/hardapproval?approvalId=CgozMzQ5OTI4MzI2EiMKIQoMCgpQaWh1IEd1cHRhEhFwaWh1QHNwb3RuYW5hLmNvbQ%3D%3D&approverName=Pihu%20Gupta&travelerName=Pihu%20Gupta&tripName=TESting%201&tripId=2418132231&voidDate=Tuesday,%2021%20Jun%20at%2002:00%20UTC", "itineraryFlightStatsUrl": "https://stage-app.spotnana.com/trips/4694735622", "appEmbedScriptUrl": "https://customjs.partner.com", "logoNavigationLink": "http://www.spotnana.com", "illustration": "https://duploservices-stage-email-assets-873909615026.s3-us-west-2.amazonaws.com/approval/spotnana-s-logo.png", "poweredBySpotnana": false, "logoutRedirectUrl": "https://www.spotnana.com/signout", "faviconUrl": "http://www.spotnana.com", "appDownloadLinks": {}, "socialMediaLinks": {}, "termsOfUse": "https://www.spotnana.com/terms/", "illustrationActionUrl": "https://www.spotnana.com/login" }, "fromEmailAddress": "no-reply@spotnana.com", "fontFamily": "Arial", "emailFontFamily": "Roboto", "fontFamilyCss": "https://duploservices-stage-email-assets-873909615026.s3.us-west-2.amazonaws.com/partners/amazon/emberDisplay.css", "emailClientConfig": { "client": "SENDGRID", "credentials": {}, "defaultSenderAddress": "test@somedomain.com", "defaultSenderName": "Test Sender" }, "clientRoutingBasePath": "string", "routingConfig": { "appHomeRoute": "/my-account" }, "privacyDisclaimer": { "show": true, "html": "</html>" } }

Updates Color config

Request

This endpoint stores Color config for the company at some entity level.

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Query
companyRolestring(CompanyRole)required

Role of the company.

Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: companyRole=TMC
Bodyapplication/jsonrequired
profileColorsArray of objects(ProfileColors)

The list of colors relating to profile.

curl -i -X PUT \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/color-config?companyRole=ORG' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "profileColors": [
      {
        "title": "PROFILE_TIER_MEMBER_COLOR",
        "color": "#FF0000"
      }
    ]
  }'

Responses

OK

Response
application/json
{ "debugIdentifier": "string", "errorMessages": [ {} ] }

Get color config

Request

This endpoint fetches the color config for the given entity.

Path
companyIdstring(uuid)required

Identifier for company.

Example: 4974a66b-7493-4f41-908c-58ba81093947
Query
companyRolestring(CompanyRole)required

Role of the company.

Enum"ORG""TMC""PARTNER_TMC""HR_FEED_CONNECTOR""TRIPS_DATA_CONNECTOR""GLOBAL"
Example: companyRole=TMC
curl -i -X GET \
  'https://developer.spotnana.com/_mock/openapi/companyapi/v2/companies/{companyId}/color-config?companyRole=ORG' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
profileColorsArray of objects(ProfileColors)

The list of colors relating to profile.

Response
application/json
{ "profileColors": [ {} ] }

Cost Centers

APIs to create and manage company cost centers.

Operations

Offices

APIs to create and manage company offices.

Operations

Departments

APIs to create and manage departments.

Operations

Service Charge Plan

APIs to manage service charge plans.

Operations

Service Charge

Operations

Company Enrollment

Operations

Company Tier

Operations