Testing the "Daily Tarot" Reading API Using Postman

Welcome to the detailed support guide on how to utilize Postman for testing the "Daily Tarot" reading API. This API delivers a personalized daily Tarot reading, offering insights into various aspects of your life including career, love, and finance.

 Last updated : 13 Dec, 2024
 Guide

1. Securing Your API Key

To start, you need an API key. Head over to https://divineapi.com/ and register to initiate your 7-day trial.

  • Select the APIs you are interested in; you can change these selections at any time. You can add or remove APIs in the future.
  • Click on checkout, fill out the sign-up form, and enter your payment details on the next page.

Your trial will begin immediately. You won't be charged during the trial period, and you can cancel anytime without incurring any charges.

  • After logging in, your API key will be visible on your dashboard on the API Key page ( https://divineapi.com/api-keys)

 

2. Importing the Postman Collection

Import our Postman collection to facilitate your API testing:

  • After logging into your Postman account:
  • Open This link: https://documenter.getpostman.com/view/27195761/2sA3Qs8rfV 
  • Click “Run in Postman” and then select “Run in Web”.
  • Select your workspace and then select ‘import’.

 

3. Configuring Your API Request

Once the collection is imported:

  • Locate the "Daily Tarot" API request.
  • Ensure the method is set to POST.
  • Use this request URL: https://astroapi-5.divineapi.com/api/v2/daily-tarot 

 

4. Setting Request Parameters

This API call necessitates only your API key. To find your API key.

  • Go to your DivineAPI dashboard > API Key page.
  • Click on “Copy” next to the API key

 Notice the difference between the key, and the Access Token.

 

Go back to Postman to set the parameters.

  • Navigate to “Authorization”, select “Bearer Token” in the Auth type, and then add the token from your Divine API profile.
  • Navigate to 'Body', select 'form_data', and then add:
    • Key : api_key | Value: <Your_API_Key>
    • lan : “en” - Enter the language.
  • Please ensure that the bearer token is exactly the same as in your profile, with no changes in spacing or formatting.

 

5. Making the Request

Hit the 'Send' button to submit your request.

 

6. Deciphering the Response

The API's response will be structured as follows:

{

{
    "success": 1,
    "data": {
        "card": "FIVE OF CUPS",
        "category": "Upright",
        "career": "The 5 of cups tarot indicates that the seeker will lose everything they have. There are high possibilities that everything will be turned upside down in their life. the seeker will lose a job and fall on the streets with nothing to hang on to.\r\nThe seeker will face discrimination and difficulties at the work front. They will be under immense pressure and broken mental stability at work. The projects the seeker working on will get spoilt or they might do a huge mistake at their projects.  Even though these difficulties are hard, the seeker will have to endure it.",
        "love": "The 5 of cups signify that the seeker will be in a very sorrowful state right now. They might have lost love or gone through a terrible trauma of love. The seeker will face never-ending arguments and fights that will break them mentally and emotionally.\r\nThe seeker will have to be bold and strong and should not become a weakling and crumble badly. This card highlights the emotional loss the seeker will undergo. The seeker should understand that they will find better love eventually.",
        "finance": "This card highlights that the seeker is in a constant loss of resources and revenue. The seeker will be in a very critical situation of their financial status. This is because of their unstable position in their work front and lack of resources in the past.\r\nThe seeker has to look at the positive outlook of their troubles and make amends in the future. It is vital that they learn from their mistakes and come back stronger. Even though the position is very depressing and discouraging, the seeker has to will to get back on their toes and stand tall.",
        "image": "https://astroapi-5.divineapi.com/public/uploads/daily_tarot/36_2.jpg",
        "image2": "https://astroapi-5.divineapi.com/public/uploads/daily_tarot/36.jpg"
    }
}
  • The API response provides the "FIVE OF CUPS" card in the upright position, detailing its impact on career, love, and finance. 
  • Each field explains potential challenges the seeker may face. 
  • Use the "image" and "image2" URLs to display the card visually.

7. Error Resolution

Ensure your API key is correctly entered if you encounter errors, as most issues are due to invalid or missing API keys.

8. Further Assistance

For additional support or inquiries, feel free to contact our customer service team at admin@divineapi.com.