Skip to content

API Usage

Architecture

Motiva has a GraphQL API. It handles all of the queries and mutations for the Motiva platform. The Stripe API is used for payment management.

Environments

Staging API: https://api2.staging.evolve.launchmotiva.io
Production API: https://api2.evolve.launchmotiva.io

Headers

app-id: evolve
Authorization: authtoken

Configuration

Initial configuration is retrieved from the API /config.

Config response (staging)
{
"publicStripeKey": "pk_test_51IrMj2KWHaHjxHojwBYUHv96jSQ3LcI9KtCvM3HT5WCnEWfslEVYusOExlHz0N7wAWJnLNWA3Qr1oY6yFPi3bnRT00dpOFcELf",
"mobileServiceUrl": "https://api2.staging.evolve.launchmotiva.io",
"pricingOptions": [
{
"duration": 28,
"durationUnit": "day",
"minPriceFilter": 40000,
"maxPriceFilter": 200000
}
],
"helpUrl": "https://static.staging.evolve.launchmotiva.io/mobiledocs/docs/faq.html",
"disableSwap": true,
"mapboxToken": "pk.eyJ1IjoidGVnYW1ja2lubmV5IiwiYSI6ImNrcDhvbWx4MTAwdGcydW4yZmszOWduNjEifQ.Gaq8cU3hF8ffFR_ddFKLTQ",
"supportEmail": "help@launchmotiva.io",
"termsOfUseUrl": "https://static.staging.evolve.launchmotiva.io/mobiledocs/docs/terms.html",
"disableFilters": true,
"privacyPolicyUrl": "https://static.staging.evolve.launchmotiva.io/mobiledocs/docs/privacy.html",
"enabledLeaseStates": [
"AZ",
"CA",
"NC",
"OH"
],
"minimumCreditScore": "650",
"creditDisclosureUrl": "https://static.staging.evolve.launchmotiva.io/mobiledocs/docs/credit-disclosure.html",
"insurancePhoneNumber": "877-212-2556",
"roadsideAssistancePhoneNumber": "844-340-9742"
}

Errors

Errors are returned within the errors array. It follows the pattern outlined in the Apollo docs.