Giter VIP home page Giter VIP logo

integrationos's Introduction

馃摉 Just launched IntegrationOS

Ship integrations, remarkably fast.

WebsiteDocumentationChangelogBlogSlackTwitter


Stop wrestling with UI libraries, hacking together data models, and figuring out authentication. Start shipping native integrations that move your business forward.

Access realtime data from any integration using a single API Forget the pain of having to manually parse through, transform and maintain hundreds of data models. Now integrating bi-directional flows for a new integration is as simple as calling a single API.

Get started

To get the most out of this guide, you'll need:

  1. An IntegrationOS account
  2. Your IntegrationOS API Key

Step 1: Backend - Create secure tokens

First, we'll add an endpoint to our backend that'll let us generate secure tokens for our frontend component.

Install the SDK

To make this easy, IntegrationOS offers native SDKs in several popular programming languages. This guide will use the popular AuthKit SDK for Node.js.

npm install @integrationos/authkit-node

Set secrets

To make calls to IntegrationOS, provide your API key. Store these values as managed secrets and pass them to the SDKs either as environment variables or directly in your app's configuration depending on your preferences.

INTEGRATIONOS_SANDBOX_API_KEY='sk_test_example_123456789'
INTEGRATIONOS_PRODUCTION_API_KEY='sk_live_example_123456789'

Create a token endpoint

Next, we'll need to add the token endpoint which will exchange the authorization token (valid for 10 minutes) for an authenticated Connected Account.

import { AuthKitToken } from "@integrationos/authkit-node";

app.post("/authkit-token", async (request, response) => {
  const authKitToken = new AuthKitToken(process.env.INTEGRATIONOS_SANDBOX_API_KEY);

// Specifying how the token will be constructed
  const token = await authKitToken.create({
    group: "org_123", // a meaningful identifier (i.e., organizationId)
    label: "Acme" // a human-friendly label (i.e., organizationName)
  });

  response.send(token);

});

Step 2: Frontend - Make AuthKit appear

Next, we'll add the AuthKit component to your frontend application.

Install the SDK

In the same fashion, IntegrationOS offers native frontend SDKs in several popular frameworks. Compatible with React, Next.js, Vue, Svelte and more.

npm install @integrationos/authkit

Use the AuthKit Component

Next, we need to add the AuthKit component and replace the token URL with the URL of the token endpoint URL you created in Step 1 of this guide.

import { useAuthKit } from "@integrationos/authkit";

const { open } = useAuthKit({
  token: {
    url: "https://api.your-company-name.com/authkit-token",
    headers: {},
  },
  onSuccess: (connection) => {},
  onError: (error) => {},
  onClose: () => {},
});

Launch the AuthKit flow

With your client and server setup complete, you can now test the authentication flow by calling open().

<button onClick={open}>Add new integration</button>

This will open the AuthKit modal so your user can:

  • Select an integration to connect
  • Be guided through the authentication flow
  • Authorize data access

Once the flow is completed, AuthKit will return a Connection object to your onSuccess callback. Each connection object contains metadata about the connected account and can be used to make API requests.

View the full guide here.

Running IntegrationOS locally

Prerequisites

Setup

  1. Copy .env-example to .env. Review and update the environment variables.

  2. Run the containers

    docker-compose up -d
  3. Load seed data

    source .env
    docker-compose exec mongo mongorestore --host localhost --nsFrom="seed_db.*" --nsTo="events-service.*" --authenticationDatabase admin -u integrationos -p $MONGO_PASSWORD /seed-data
  4. Run migrations

    source .env
    docker-compose -f docker-compose.data.yml run --rm migrate-before
    docker-compose -f docker-compose.data.yml run --rm migrate-after

Other actions

Connecting to a MongoDB shell

source .env
docker-compose exec mongo mongosh -u integrationos -p $MONGO_PASSWORD --authenticationDatabase=admin events-service

License

IntegrationOS is released under the GPL-3.0 license.

integrationos's People

Contributors

krish221997 avatar moekatib avatar paulkr avatar peterkuczera avatar samgj18 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

integrationos's Issues

Add security contact

Hi @paulkr,

I got the following phishing email (note the domain) and there isn't any contact info on your website or a security policy on GH. Wasn't sure of any other way of forwarding this

image

Best,
Ale

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.