Skip to content

Does the _return_http_data_only parameter work? #4

@StevenTollanis

Description

@StevenTollanis

Hey,

I'm trying to use the get_device_datasource_data_by_id method but also want to get the headers, my current call is like below:

api_response = api_instance.get_device_datasource_data_by_id(ds["DeviceId"], ds["DataSourceRecordId"], start=twenty_four_hours_ago, end=now, _return_http_data_only=False)

But still just getting the JSON response without any other info.

When I try to print its type, it's just

print(type(api_response))
<class 'logicmonitor_sdk.models.device_data_source_data.DeviceDataSourceData'>

I review the code on logicmonitor_sdk\api_client.py line 179, and from this I learned that I had to add _return_http_data_only, are there any other parameter I need to enable?

 if _return_http_data_only:
            return (return_data)
        else:
            return (return_data, response_data.status,
                    response_data.getheaders())

Thanks for the help

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions