Developers | Hub Delivery
  • Visão geral
    • Primeiros passos
    • Fluxos
    • Canais de venda
      • Ifood
      • Rappi
      • Pede Pronto
      • Delivery Vip
      • Pekus
      • Zé Delivery
      • AiQFome
      • Delivery Much
      • Accon
      • Jota Já
      • Alloy
      • Goomer
      • Wabiz
      • Delivery Direto
      • Super Menu
      • VTEX
      • Oi Menu
      • TwData
      • Neemo
      • PedZap
      • Americanas Delivery
      • On Pedidos
    • Operadores logísticos
      • Loggi
      • Foody Delivery
      • Bdoo
    • Programas de fidelidade
      • Padrão
      • Cliente Fiel
    • Glossário
    • Boas práticas
  • API Reference
    • Licenses
      • Authentication
      • Sign Up
    • Merchants
      • Sale Channels
      • Logistic Operators
    • Orders
      • Events
      • Order
      • Cancellations
    • Loyalty
      • Programs
      • Affiliations
      • Credits
      • Redeem
      • Balance
      • Extract
    • Catalog
      • Catalogs
      • Menus
      • Categories
      • Item Offers
      • Items
      • Option Groups
      • Options
    • Hooks
  • Changelogs
    • 04/2023
    • 11/2022
    • 10/2022
    • 09/2022
    • 08/2022
    • 07/2022
    • 06/2022
    • 05/2022
  • Suporte
Powered by GitBook
On this page
  1. API Reference
  2. Licenses

Authentication

Realiza a criação de um token de acesso aos serviços

POST https://{account}.myhubdelivery.io/license-manager/api/v1/oauth/token

Content-Type: application/x-www-form-urlencoded

Request Body

Name
Type
Description

client_id*

String

<<AccountClientID>>

client_secret*

String

<<AccountClientSecret>>

grant_type*

String

client_credentials

{
    "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJBY2NvdW50SWQiOiIyYllsNndnTTlaIiwiQWNjb3VudFNsdWciOiJodWJkZWxpdmVyeSIsIk1lcmNoYW50cyI6IltdIiwicm9sZSI6IkFwaVB1YmxpYyIsIkFwaVB1YmxpYyI6InRydWUiLCJTY29wZXMiOiJpby5hbGwiLCJuYmYiOjE2NTI5ODQ4MDEsImV4cCI6MTY1MzA3MTIwMSwiaWF0IjoxNjUyOTg0ODAxfQ.V717416_87wxYHlpFx587l0dNEwTjdlEmNpPzOua2nbFlN6H2RQ",
    "token_type": "Bearer",
    "expires_in": 86400
}
{
    "type": "https://tools.ietf.org/html/rfc7235#section-3.1",
    "title": "Unauthorized",
    "status": 401,
    "traceId": "00-cd0c0257a67e9a3fe57dc8c160e01607-b5994934dd13d84f-01"
}

Exemplo da requisição em formato CURL

curl --location --request POST 'https://{account}.myhubdelivery.io/license-manager/api/v1/oauth/token' \CU
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'client_id=AccountClientID>>' \
--data-urlencode 'client_secret=AccountClientSecret>>' \
--data-urlencode 'grant_type=client_credentials'
PreviousLicensesNextSign Up

Last updated 3 years ago