I ran the above code, but an error occurred. When I ran it a few months ago, it worked fine without any errors. Do you know how to solve it?

  Kiến thức lập trình

from notionai import NotionAI
from config import *

topic = “test”

ai = NotionAI(NOTION_TOKEN,NOTION_SPACE_ID)
res = ai.blog_post(f’write a blog about {topic}’)

print(res)

data: {“errorId”:”7a0f6b56-c899-4246-b572-fee21d1bb960″,”name”:”ValidationError”,”debugMessage”:”Invalid input.”,”message”:”Something went wrong. (400)”}, error: ‘type’

I ran the above code, but an error occurred. When I ran it a few months ago, it worked fine without any errors. Do you know how to solve it?

I thought it was an API key issue, so I went into notion, pressed F12, found the space id in token_v2 and localstorge, and updated it again.

New contributor

Jinhyuk An is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

LEAVE A COMMENT