# Account does not enabled REST API."

**URL:** <https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180>\
**Category:** API and Webhooks\
**Tags:** api\
**Created:** [August 30, 2023, 2:05am UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180 "2023-08-30T02:05:01Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![codanji](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/codanji/32/51168_2.png) [@codanji](https://devforum.zoom.us/u/codanji)\
**Post date:** [August 30, 2023, 2:05am UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/1 "2023-08-30T02:05:01Z")

</div>

Hey everyone,

I have a Zoom One Pro account and connecting a wordpress website to programatically retrieve all meetings for a user. The access token is being retrieved correctly using Server to Server Ouath2.0 setup which I created using Zoom developer. When i use the access token the following way however, when I check my error\_logs im getting the following:

**Errors:**  
[30-Aug-2023 01:46:09 UTC] Zoom HTTP Response Code:400  
[30-Aug-2023 01:46:09 UTC] Zoom Get All Meetings Response:{“code”:200,“message”:“Account does not enabled REST API.”}

**Here is how I’m calling the API:**

```auto
function get_all_zoom_meetings() {
    $token = get_zoom_access_token();
    if(!$token) {
        return false;
    }
   
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, 'https://api.zoom.us/v2/users/me/meetings');
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');

    $headers = array();
    $headers[] = 'Authorization: Bearer ' . $token;
    curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
    
    $result = curl_exec($ch);
    
    // Logging the HTTP Response Code
    $http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
    error_log('Zoom HTTP Response Code:' . $http_code);

    if (curl_errno($ch)) {
        error_log('Zoom Get All Meetings Error:' . curl_error($ch));
    } else {
        error_log('Zoom Get All Meetings Response:' . $result);
    }
    curl_close($ch);
    
    return json_decode($result, true);
}

add_shortcode('zoom_test', 'zoom_test_function');

```

Now when I setup the same thing in postman im getting the status code of 200 and everything is working fine, so Im not sure why this error is occurring. In postman im able to create and retrieve meetings using the same credentials and account\_id.

Please let me know how to solve this!

---

<div class="post-metadata">

**Author:** ![michael.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael.zoom/32/37213_2.png) [@michael.zoom](https://devforum.zoom.us/u/michael.zoom)\
**Post date:** [August 31, 2023, 2:02pm UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/2 "2023-08-31T14:02:07Z")

</div>

Hey @codanji , welcome and thanks for posting! Sorry about the blockage here!

Because requests work in Postman, I’d imagine this has to be an issue with the format of the HTTPS request being sent to the Zoom API.

The same access token works in Postman, but does not using this function? If you use this app to get a token, do your curl requests work? [GitHub - zoom/server-to-server-oauth-token: Utility script to generate a Zoom Server-to-Server Oauth Token and copy to clipboard](https://github.com/zoom/server-to-server-oauth-token)

---

<div class="post-metadata">

**Author:** ![ecodes](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/ecodes/32/52221_2.png) [@ecodes](https://devforum.zoom.us/u/ecodes)\
**Post date:** [September 20, 2023, 4:19pm UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/3 "2023-09-20T16:19:27Z")

</div>

Sorry, i have the same problem.  
I created a Server-To-Server OAuth App and i get the AccessToken without problems, but when i try to use the API iget the {“code”:200,“message”:“Account does not enabled REST API.”}  
I get the same error on Postman.  
I have ok the scopes on the app…

I really dónt know what else i can do  
thanks

PD: i just created another Server-To-Server OAuth App and i get the same error.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/6/1/614bdd549b610bbaa46ff934617683a02bdaa03c.png) [@system](https://devforum.zoom.us/u/system)\
**Post date:** [September 21, 2023, 8:28pm UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/4 "2023-09-21T20:28:51Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [September 21, 2023, 8:30pm UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/5 "2023-09-21T20:30:16Z")

</div>

Hi @ecodes , were you able to try the sample app? If not, please refer to this post or our Postman workspace to get the token:

> [@Issue with Zoom API - Migration from JWT to Server-to-Server OAuth - PHP cUrl -code":200,"message":"Account does not enabled REST API."](https://devforum.zoom.us/t/issue-with-zoom-api-migration-from-jwt-to-server-to-server-oauth-php-curl-code-200-message-account-does-not-enabled-rest-api/95052/7):
>
> A request for account\_credentials requires an account\_id in the URL, and a ClientID/ClientSecret in the request itself: " To use account credentials to get an access token for your app, call the Zoom OAuth token API with the account\_credentials grant\_type , your account\_id , and your client ID and client secret, [base64 encoded](https://www.base64encode.org/) (encode your client ID and client secret with a colon between them, e.g. client\_id:client\_secret )." By the way, it’s far easier to create/compose these requests using…

[https://www.postman.com/zoom-developer/workspace/zoom-public-workspace/folder/22097587-0021aa9e-17f5-478e-b106-dfb31b930153](https://www.postman.com/zoom-developer/workspace/zoom-public-workspace/folder/22097587-0021aa9e-17f5-478e-b106-dfb31b930153)

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [September 21, 2023, 8:30pm UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/7 "2023-09-21T20:30:44Z")

</div>



---

<div class="post-metadata">

**Author:** ![ecodes](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/ecodes/32/52221_2.png) [@ecodes](https://devforum.zoom.us/u/ecodes)\
**Post date:** [September 22, 2023, 7:59am UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/8 "2023-09-22T07:59:13Z")

</div>

Hello Gianni, finally i find a PHP code with Curl that works, i publish it on github to help another developers woth the same problem!

> **[GitHub - CiroArtigot/Zoom-Server-to-Server-OAuth-API: This is a PHP code to...](https://github.com/CiroArtigot/Zoom-Server-to-Server-OAuth-API)**
>
> This is a PHP code to access the Zoom API with a Server-to-Server-OAuth app - GitHub - CiroArtigot/Zoom-Server-to-Server-OAuth-API: This is a PHP code to access the Zoom API with a Server-to-Server...

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [September 25, 2023, 9:26pm UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/9 "2023-09-25T21:26:26Z")

</div>

Thank you @ecodes for sharing PHP code sample for Server-to-Server OAuth access token generation and API calls!

---

<div class="post-metadata">

**Author:** ![bloommedico](https://avatars.discourse-cdn.com/v4/letter/b/e0b2c6/32.png) [@bloommedico](https://devforum.zoom.us/u/bloommedico)\
**Post date:** [October 26, 2023, 9:42am UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/10 "2023-10-26T09:42:17Z")

</div>

Hello all,

I am facing the same issue previously it was working before but it is not working now and it is showing me this error

```auto
Array
(
    [code] => 200
    [message] => Account does not enabled REST API.
)

```

When I am creating a meet url my meeting array is

```auto
Array
(
    [topic] => Booking Meeting
    [agenda] => Booking Meeting
    [settings] => Array
        (
            [host_video] => 
            [participant_video] => 1
            [join_before_host] => 1
            [audio] => 1
            [approval_type] => 2
            [waiting_room] => 
        )

    [password] => J2zD7L
)

```

Can you please help me in this case

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [October 26, 2023, 2:18pm UTC](https://devforum.zoom.us/t/account-does-not-enabled-rest-api/94180/11 "2023-10-26T14:18:59Z")

</div>

Hi @bloommedico , there are a few threads on this. Can you please perform a search?

What app type are you using to generate an access token? Does it have the scopes needed for the endpoint?

Please note that when creating an access token for S2S OAuth app, account id is required, but not for OAuth 2.0 app type.

Refer to our postman public workspace for some more guidance: [Postman](https://www.postman.com/zoom-developer/workspace/zoom-public-workspace/folder/22097587-e7ae0b09-de23-433a-8dde-c96a57c775fd)
