Re: Authentication required

9251 0
Showing results for 
Search instead for 
Did you mean: 
5 - Automation Enthusiast
5 - Automation Enthusiast

when i create records,got a reeor about Authentication,the message is:{“error”:{“type”:“AUTHENTICATION_REQUIRED”,“message”:“Authentication required”}}

this is my code and data:

url = “
h = {
data_list = {“records”: [{“fields”: {“Name”: “a”, “Priority”: 3}}]}

13 Replies 13

You’re not using the right syntax for any of those lines.

Go to and it will give you the appropriate syntax to use for each one of your bases and for each function you want to perform.

I developed it based on the API

Can you tell me what’s wrong


On first glance, it looks a bit odd until you realize this is Python.

Hi @wenju_fan, and welcome to the community!

I believe this is Python because the json.dumps() method caught my eye and this only exists in Python. Can you confirm this is Python?

I believe the issue is in the header - change it to this:

'Authorization' : 'Bearer ' + cAirtableAPIKey,

Yeah,this is python
as you said,I tried this:


If you have a demo,i will appreciate it if you can send me a copy



Okay - let’s be sure about your code - can you publish the latest version?

4 - Data Explorer
4 - Data Explorer

the syntax looks fine. Probably you got the key or the url wrong.

5 - Automation Enthusiast
5 - Automation Enthusiast

I’m running into the same issue when making any API call in the iOS Shortcuts app on my iPhone, but it works fine with curl and Postman, and even Shortcuts on my Macbook.
header: “Authorization”:“keyxxxxxxxxxxxxx8Ng”,

I’ve double and triple checked and copypasted the url and key between the apps where it works and the ones where it doesn’t, but nothing changes