Forum Discussion

API_User's avatar
API_User
Equinix Employee
6 years ago
Solved

Smart Hands ticket api

Hello guys, I am new in using curl and I have a qeustion.
How it looks the final example autharization form + get smart hands type.

 

curl -X POST 'https://api.equinix.com/oauth2/v1/token'
-H "content-type: application/json"
-d '{
"grant_type": "client_credentials",
"client_id": "ABCDE12345",
"client_secret": "FGHIJ67890"
}'

and 

 

curl -X GET "https://api.equinix.com/v1/orders/smarthands/types"
-H "content-type: application/json"
-H "authorization: Bearer qwErtYxxxxxxxcdefGHI"


I don't understand how to combine these two example in one and why I have to use second time

-H "authorization: Bearer qwErtY8zyW1abcdefGHI"
  • Hi there,

    The first API call is an auth service where token is returned after authentication is successful. This token is valid for 60 minutes upon successful authentication and has to be passed in the header for subsequent APIs calls.
    Note that this is applicable all endpoints and not limited to smarthands APIs.
    Hope this clarifies
    Cheers,
    Zac

1 Reply

  • API_User's avatar
    API_User
    Equinix Employee
    Hi there,

    The first API call is an auth service where token is returned after authentication is successful. This token is valid for 60 minutes upon successful authentication and has to be passed in the header for subsequent APIs calls.
    Note that this is applicable all endpoints and not limited to smarthands APIs.
    Hope this clarifies
    Cheers,
    Zac

Featured Places

  • Node avatar for Discussions

    Discussions

    Engage with industry experts, share insights, ask questions, and grow your network.
  • Node avatar for Ideas

    Ideas

    Share your ideas and help shape the future of Equinix!
  • Node avatar for Groups

    Groups

    Ready to collaborate? Join a Group or upcoming beta program.
  • Node avatar for What's New

    What's New

    Stay ahead with the latest from Equinix. Discover new product announcements, insightful tutorials, and practical use cases.
  • Node avatar for Events

    Events

    Your Guide to Upcoming Events - Online, Hybrid, and In-Person!