Giter VIP home page Giter VIP logo

Comments (5)

justjake avatar justjake commented on May 18, 2024 7

@muuvmuuv I am referring to the OAuth flow for public integrations which involves sending a POST request to https://api.notion.com/v1/oauth/token

from notion-sdk-js.

rhart92 avatar rhart92 commented on May 18, 2024 1

/v1/oauth/token has now been incorporated into the SDK as of v2.2.11 🎉

from notion-sdk-js.

muuvmuuv avatar muuvmuuv commented on May 18, 2024

Do you mean how you authorize? Head over to https://www.notion.so/my-integrations and create a new integration and paste the token into the client.

from notion-sdk-js.

mogita avatar mogita commented on May 18, 2024

For future searchers, although lacking OAuth functions from this library is apparently a miss, implementing it, for example with Express, can be fairly straight forward since it's not OAuth2. You redirect your user to the /oauth/authorize endpoint, having them allow access, and Notion redirects user's browser back to your redirect_uri so you can use the code to call /oauth/token for the access token which represents the user. And this wraps up the whole process. Currently Notion API doesn't require you to encrypt or decrypt anything which is way easier than many other OAuth providers.

This is not the most accurate description of the OAuth process but you get the gist. Also you can follow this article if you just want some working code https://naomiperez.netlify.app/notion-oauth-flow/

from notion-sdk-js.

cooljameswei avatar cooljameswei commented on May 18, 2024

Hi @mogita
Could you please share the that repo?
I'm currently working on a project which require notion public integration.
I've done with internal integration by specify certain pages but get stuck with public integration(OAuth 2).
I'm looking forward to your reply.

from notion-sdk-js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.