Skip to content

oktadev/okta-node-postgres-todo-example

master
Switch branches/tags
Code
This branch is 3 commits ahead of nickolasfisher:master.
Contribute

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Node PostgreSQL To Do Example Application

This is the companion repository for a blog post on the Okta Developer website.

Getting Started

Clone the repository by running:

git clone https://github.com/oktadeveloper/okta-node-postgres-todo-example.git

Restore the NPM packages:

npm install

Create the Item Table

  • Using your Postgres query tool of choice, connect to your Postgres developer server
  • Create a new database named todolist (or use an existing development database)
  • Create the Item table in the database using the following command
CREATE TABLE Item (
  id serial primary key
  , title varchar(100)
  , description text
  , isComplete boolean
);

Configuration

  • Copy the included .env.sample file to .env
  • Update the configuration in this file to match your environment, such as your Postgres database connection
  • Sign up for a free Okta developer account
  • Create a new Web application in the Okta Developer Dashboard
  • Change the port for the Base and redirect URIs to use 3000 (e.g. Login redirect URI http://localhost:3000/authorization-code/callback)
  • Update the Okta configuration settings in the .env file with your Okta application's Client Id, Client secret, and Okta Org Url (e.g. https://dev-123456.okta.com)

Run the Application

Then run the application from within the root folder with:

node index.js

Getting Help

Please pose any questions about the blog post in the comments section of the blog post page.

Any questions about Okta in particular can be posted on the Okta Developer Forum.

License

Apache 2.0

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 71.2%
  • HTML 28.8%