Getting Started with Ordermentum API: Authentication and First Steps

Introduction

The Ordermentum API allows developers to integrate with our platform for managing orders, products, purchasers, and more. To interact with the API, you need to authenticate your application by obtaining a Bearer Token using OAuth2.

We're Making Improvements...

We're enhancing our authentication process to better protect your applications. Starting soon, all access requests will require a client_id, client_secret, and refresh token for security. This change will provide stronger protection against unauthorized access or misuse of credentials.

We will also be moving all endpoints that currently use app.ordermentum.com to api.ordermentum.com for consistency.

Once updated, please ensure your applications are prepared to handle these new requirements. For detailed information about the changes, we'll share more details in due course.

Reach out to us at [email protected] if you have any questions or need further support.

Obtaining an API Token

To start making requests to the Ordermentum API, authenticate your application and obtain an access token.

  • The access token is valid for 24 hours.
  • After expiration, refresh it using the OAuth2 token refresh flow.

Example POST request to obtain a token:

curl -X POST "https://app.ordermentum.com/v1/auth" \
     -H "Content-Type: application/json" \
     --data '{"username":"[email protected]","password":"hunter2"}'

Response: A JSON object containing the API token, e.g.,

{
  "access_token": "YOUR_API_TOKEN",
  "token_type": "Bearer"
}

Using the API Token

Once obtained, include the API token in every request's Authorization header.

Example GET request with the API token:

curl -X GET "https://api.ordermentum.com/v2/orders" \
     -H "Authorization: Bearer YOUR_API_TOKEN"

What’s Next
  • Retrieve Orders – Learn how to fetch orders and apply filters for more specific results.
  • Managing Products – Understand how to create and update product details through the API.