Neltify CMS Preview Link gives error: This endpoint requires a Bearer token

Hello!

Thank you for a great product!

I have an issue, when I click the “view preview” link in Netlify CMS nothing happens and I get this error in the console: {"code":401,"msg":"This endpoint requires a Bearer token"}

The preview works in the editor.

What am I doing wrong?

config.yml:

backend:
name: git-gateway
repo: myrepo
branch: branchname (not master branch)

publish_mode: editorial_workflow

collections:
- name: "blog" 
label: "Blog" 
folder: "src/blog" 
create: true 
slug: "{{slug}}" 
preview_path: "blog/{{slug}}"

admin/index.html

  • I use the free settings for Netlify Identity (Level 0)

  • I have git gateway configured and I can log in to Netlify CMS and create content, I do not have any roles specified for the git gateway config though

  • I use manual deployment and the “Deploy preview” setting under “Deploy context” is set to “Any merge request against your production branch / branch deploy branches”

Thank you for any help on this!

It seems that I missed some information in the docs.
I guess I have to use continuous deployment in order to get the “view preview” link to work!

1 Like