# Zoom Phone Call Logs 2031 Error - Zoom Phone Not Enabled

**URL:** <https://devforum.zoom.us/t/zoom-phone-call-logs-2031-error-zoom-phone-not-enabled/101429>\
**Category:** API and Webhooks\
**Tags:** phone, api\
**Created:** [January 8, 2024, 7:44pm UTC](https://devforum.zoom.us/t/zoom-phone-call-logs-2031-error-zoom-phone-not-enabled/101429 "2024-01-08T19:44:46Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![chandler.s](https://avatars.discourse-cdn.com/v4/letter/c/e9a140/32.png) [@chandler.s](https://devforum.zoom.us/u/chandler.s)\
**Post date:** [January 8, 2024, 7:44pm UTC](https://devforum.zoom.us/t/zoom-phone-call-logs-2031-error-zoom-phone-not-enabled/101429/1 "2024-01-08T19:44:46Z")

</div>

Hello!

I have been running into some issues with connecting to our account. I am going to post the code I am using to authenticate. I am running to the issue with code 2031 when I send a GET request to the endpoint: `/accounts/{accountId}/phone/call_logs`

Error I get back:

{‘code’: 2031, ‘message’: ‘Zoom Phone has not been enabled for this account.’}

However, I have gone through a bunch of steps that should solve this issue.

- We have a business/Enterprise Account

\*We have the correct scopes to our Server-to-Server OAuth App

\*We have paid in full balance on our account

\*We have added the correct license onto our account owner and have made the OAuth app through that user.

CODE:

Auth Code:

import requests  
import base64  
import json

# Zoom OAuth credentials

client\_id = ‘client\_id’  
client\_secret = ‘client\_secret’

# Encode your credentials

credentials = base64.b64encode(  
f’{client\_id}:{client\_secret}'.encode(‘utf-8’)).decode(‘utf-8’)

# Zoom’s OAuth token endpoint

url = ‘[https://zoom.us/oauth/token?grant\_type=client\_credentials](https://zoom.us/oauth/token?grant_type=client_credentials)’

# Set the headers

headers = {  
“Content-Type”: “application/x-www-form-urlencoded”,  
‘Authorization’: f’Basic {credentials}’  
}

# Make the POST request

response = requests.post(url, headers=headers)

access\_token\_full = response.json()

# Get the access token from the response

access\_token = response.json().get(‘access\_token’)

GET Request Code:

# Zoom’s Phone Call Logs API endpoint

accountId = ‘account\_id’

url = f’[https://api.zoom.us/v2/accounts/{accountId}/phone/call\_logs](https://api.zoom.us/v2/accounts/%7BaccountId%7D/phone/call_logs)’

print(url)

# Set the headers

headers = {  
‘Authorization’: f’Bearer {access\_token}',  
‘Content-Type’: ‘application/json’  
}

params = {  
‘from’: ‘2022-01-01’,  
‘to’: ‘2022-01-31’,  
‘page\_size’: 300,  
‘type’: ‘all’  
}

# Make the GET request

response = requests.get(url, headers=headers, params=params)

# Print the response

print(response.json())

Message that gets printed:  
{‘code’: 2031, ‘message’: ‘Zoom Phone has not been enabled for this account.’}

Any help around this would be great. I have went through both the Master API and regular API and I am getting the same results.

---

<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:** [January 8, 2024, 8:03pm UTC](https://devforum.zoom.us/t/zoom-phone-call-logs-2031-error-zoom-phone-not-enabled/101429/2 "2024-01-08T20:03:16Z")

</div>

Hi @chandler.s ,

1. To confirm, you have a valid [Zoom Phone plan](https://developers.zoom.us/docs/api/rest/other-references/plans/#zoom-phone-plans)?

> [@chandler.s](#):
>
> # Zoom’s OAuth token endpoint
> 
> url = ‘[https://zoom.us/oauth/token?grant\_type=client\_credentials](https://zoom.us/oauth/token?grant_type=client_credentials)’

1. There should be no query parameters. Please see the appropriate REST body parameters [here](https://developers.zoom.us/blog/s2s-token-generation-troubleshoot/#server-to-server-oauth-token-generation-error-bad-request). You can also use our [public workspace](https://www.postman.com/zoom-developer/workspace/zoom-public-workspace/request/22097587-82698a23-7af5-4f3f-bf2e-a62c3eb8903d?tab=body&ctx=documentation):  
 ![image](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/3/b/3b0d569e0d4f31a2e77da769b32e2d1b52c93487.png)

I wonder if the token you generated is inappropriately scoped. Are you able to access other endpoints without issue?

If you do have a Zoom Phone plan, please try re-generating a token based on the guidance I shared and query the endpoint once more.

---

<div class="post-metadata">

**Author:** ![chandler.s](https://avatars.discourse-cdn.com/v4/letter/c/e9a140/32.png) [@chandler.s](https://devforum.zoom.us/u/chandler.s)\
**Post date:** [January 9, 2024, 5:03pm UTC](https://devforum.zoom.us/t/zoom-phone-call-logs-2031-error-zoom-phone-not-enabled/101429/4 "2024-01-09T17:03:16Z")

</div>

Hello Gianni,

Thanks for getting back to me, I got everything working. Thank you so much for your assistance and help!

---

<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:** [January 10, 2024, 5:03pm UTC](https://devforum.zoom.us/t/zoom-phone-call-logs-2031-error-zoom-phone-not-enabled/101429/5 "2024-01-10T17:03:59Z")

</div>

Closed on January 10, 2024, 5:03pm UTC

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:** [January 10, 2024, 5:40pm UTC](https://devforum.zoom.us/t/zoom-phone-call-logs-2031-error-zoom-phone-not-enabled/101429/6 "2024-01-10T17:40:26Z")

</div>

Happy to help! Glad things are resolved!
