IBM Cloudability

IBM Cloudability

 View Only
Expand all | Collapse all

Cloudability API always reports 500 error

Apptio Community Member

Apptio Community MemberThu September 21, 2023 03:51 PM

  • 1.  Cloudability API always reports 500 error

    Posted Thu September 21, 2023 03:51 PM


  • 2.  RE: Cloudability API always reports 500 error

    Posted Thu September 21, 2023 05:30 PM

    Hey @Chen He, it looks like you are missing an item at the end of the URL. Do you need to add "measures" ?




  • 3.  RE: Cloudability API always reports 500 error

    Posted Thu September 21, 2023 06:24 PM

    Even with that, it reports 500. No matter what url I reuqest, always 500. If it is url issue, it should not response 500 but service not available or operation not allowed (405), right? It should not be 5xx error which means server side problem. 




  • 4.  RE: Cloudability API always reports 500 error

    Posted Fri September 22, 2023 01:57 PM

    Hello? Any update on this?




  • 5.  RE: Cloudability API always reports 500 error

    Posted Sun September 24, 2023 01:24 PM

    @Chen He

    Your assumptions on which code should be returned is not entirely accurate.  A 500 error does result from a server-side error, because it could not process your request.  It likely could not process the request because of missing or inaccurate parameters, based on my experience.  This would reach the server to be processed, but the server would not have enough parameters to know how to respond properly, thus responding with a 500.

    Looking at the API Endpoint that you're hitting, you're telling Cloudability "I want to run a Cost Report", but you're not telling it any details as to what you're looking for in the report.  It doesn't know the Date Range, which Dimensions & Metrics, any Filters, etc.  I'm going to provide a couple of examples for you below that I expect to return results, as well as a link to our API Documentation, specifically for Cost Reports.

    Example 1 : "I want to know information about the Dimensions & Metrics that I can use with Cost Reports."

    • In this example, you are not actually getting cost data, so you don't need to provide a time frame or filters.  This is only going to return the Dimensions & Metrics available for your organization, which is helpful in determining the proper terminology to use when building your API request.
    • API URL = https://api.cloudability.com/v3/reporting/cost/measures

    Example 2 : "I want to know all of my cloud costs for July 2023, split by cloud vendor."

    If those still do not work for you, I would recommend contacting your TAM or submitting a support ticket so that our team of experts can review the situation.  Please be sure to include a screenshot if possible, or at least the time & date that you attempted to hit the endpoint along with the traceID and uniqueID from the response.  This will help them to locate your specific request so it could be analyzed.



    ------------------------------
    Phillip Purcell
    Senior FinOps Consultant
    Apptio Apptio
    ------------------------------



  • 6.  RE: Cloudability API always reports 500 error

    Posted Mon September 25, 2023 02:40 PM

    Thank you for the reply, Phllip. 

    Followed your suggestion on this URL: "

    Same issue in the attached screenshot. Who is Spotnana.com's TAM? How to submit a ticket? I just joined Spotnana in a month, really appreciate if you can shed some lights on this. Attached return headers of my request. 


    If possible, I am happy to have a short online meeting session with support engineers from Apptio.com. Appreciate all your helps!



  • 7.  RE: Cloudability API always reports 500 error

    Posted Mon September 25, 2023 02:48 PM


    Hi @Chen He, will DM you additional information on contacts and this post shows you how to submit a support request.  I will also forward this to your Cloudability TAM.  Thank you!




  • 8.  RE: Cloudability API always reports 500 error

    Posted Mon September 25, 2023 04:26 PM

    Hi @Chen He - your screenshot shows "Bearer Token" for Authorization. I use Basic Auth with the Cldy API (Cldy API Key goes in the Username field, Password field remains blank). Could that be the problem?




  • 9.  RE: Cloudability API always reports 500 error

    Posted Mon September 25, 2023 04:36 PM

    Thank you for the reply, Jeff.  I assume the API key you got is from the header of login response. I followed your method. It gives me 401. It sounds like,

    never pass the authentication process. 




  • 10.  RE: Cloudability API always reports 500 error

    Posted Mon September 25, 2023 07:19 PM

    Hi @Chen He, the API key is static and tied to your user account and can be generated within the "Manage Profile" section of Cloudability as described here. Authentication is described on this page here.




  • 11.  RE: Cloudability API always reports 500 error

    Posted Tue September 26, 2023 09:12 AM

    Hi Chen, See @Andrew Midgley's last reply. 




  • 12.  RE: Cloudability API always reports 500 error

    Posted Tue September 26, 2023 06:41 PM

    It works after directly using the api token generated from cloudability and use it as username in basic auth mode. Thank all for the help.