Skip to content

Using Library for https://ads-api.twitter.com/3/accounts #13

@CreativeTransmissions

Description

@CreativeTransmissions

Hi there,

I'm evaluating this library for potential use in an upcoming project, however I'm having trouble calling the above request.

Is this possible with this library?

I am calling:
$tmhOAuth->reconfigure(array('host'=>'ads-api.twitter.com'));

I have instanciated the class with consumer_key,consumer_secret, token, secret and bearer.

The response is always:

{"errors":[{"code":"UNAUTHORIZED_ACCESS","message":"This request is not properly authenticated"}],"request":{"params":{}}}

I tried by adapting your cli examples for user_request and apponly_request:

$code = $tmhOAuth->apponly_request(array(
'url' => $tmhOAuth->url('3/accounts')
));

or

$url = '3/accounts';
$request_url = $tmhOAuth->url($url);
$code = $tmhOAuth->user_request(array(
'url' => $request_url
));

  • both give me an authentication error.

Any advice would be greatly appreciated.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions