Skip to content
This repository has been archived by the owner on Oct 31, 2024. It is now read-only.

Commit

Permalink
Merge pull request #6 from openint-dev/feat/add-greenhouse-connector
Browse files Browse the repository at this point in the history
feat: [wip] add greenhouse connector
  • Loading branch information
jatinsandilya authored Apr 24, 2024
2 parents a56ad91 + d0f149e commit da24342
Show file tree
Hide file tree
Showing 12 changed files with 97 additions and 0 deletions.
2 changes: 2 additions & 0 deletions apps/app-config/connectors/connectors.def.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {default as connectorFirebase} from '@openint/connector-firebase/def'
import {default as connectorForeceipt} from '@openint/connector-foreceipt/def'
import {default as connectorFs} from '@openint/connector-fs/def'
import {default as connectorGoogle} from '@openint/connector-google/def'
import {default as connectorGreenhouse} from '@openint/connector-greenhouse/def'
import {default as connectorHeron} from '@openint/connector-heron/def'
import {default as connectorHubspot} from '@openint/connector-hubspot/def'
import {default as connectorLunchmoney} from '@openint/connector-lunchmoney/def'
Expand Down Expand Up @@ -52,6 +53,7 @@ export const defConnectors = {
foreceipt: connectorForeceipt,
fs: connectorFs,
google: connectorGoogle,
greenhouse: connectorGreenhouse,
heron: connectorHeron,
hubspot: connectorHubspot,
lunchmoney: connectorLunchmoney,
Expand Down
8 changes: 8 additions & 0 deletions apps/app-config/connectors/connectors.merged.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ import {default as connectorFs_def} from '@openint/connector-fs/def'
import {default as connectorFs_server} from '@openint/connector-fs/server'
import {default as connectorGoogle_def} from '@openint/connector-google/def'
import {default as connectorGoogle_server} from '@openint/connector-google/server'
import {default as connectorGreenhouse_def} from '@openint/connector-greenhouse/def'
import {default as connectorGreenhouse_server} from '@openint/connector-greenhouse/server'
import {default as connectorHeron_def} from '@openint/connector-heron/def'
import {default as connectorHeron_server} from '@openint/connector-heron/server'
import {default as connectorHubspot_def} from '@openint/connector-hubspot/def'
Expand Down Expand Up @@ -133,6 +135,11 @@ const connectorGoogle = {
...connectorGoogle_server,
}

const connectorGreenhouse = {
...connectorGreenhouse_def,
...connectorGreenhouse_server,
}

const connectorHeron = {
...connectorHeron_def,
...connectorHeron_server,
Expand Down Expand Up @@ -288,6 +295,7 @@ export const mergedConnectors = {
foreceipt: connectorForeceipt,
fs: connectorFs,
google: connectorGoogle,
greenhouse: connectorGreenhouse,
heron: connectorHeron,
hubspot: connectorHubspot,
lunchmoney: connectorLunchmoney,
Expand Down
2 changes: 2 additions & 0 deletions apps/app-config/connectors/connectors.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {default as connectorFirebase} from '@openint/connector-firebase/server'
import {default as connectorForeceipt} from '@openint/connector-foreceipt/server'
import {default as connectorFs} from '@openint/connector-fs/server'
import {default as connectorGoogle} from '@openint/connector-google/server'
import {default as connectorGreenhouse} from '@openint/connector-greenhouse/server'
import {default as connectorHeron} from '@openint/connector-heron/server'
import {default as connectorHubspot} from '@openint/connector-hubspot/server'
import {default as connectorLunchmoney} from '@openint/connector-lunchmoney/server'
Expand Down Expand Up @@ -50,6 +51,7 @@ export const serverConnectors = {
foreceipt: connectorForeceipt,
fs: connectorFs,
google: connectorGoogle,
greenhouse: connectorGreenhouse,
heron: connectorHeron,
hubspot: connectorHubspot,
lunchmoney: connectorLunchmoney,
Expand Down
9 changes: 9 additions & 0 deletions apps/app-config/connectors/meta.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,15 @@ module.exports = [
server: '@openint/connector-google/server',
},
},
{
name: 'greenhouse',
dirName: 'connector-greenhouse',
varName: 'connectorGreenhouse',
imports: {
def: '@openint/connector-greenhouse/def',
server: '@openint/connector-greenhouse/server',
},
},
{
name: 'heron',
dirName: 'connector-heron',
Expand Down
1 change: 1 addition & 0 deletions apps/app-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
"@openint/connector-foreceipt": "workspace:*",
"@openint/connector-fs": "workspace:*",
"@openint/connector-google": "workspace:*",
"@openint/connector-greenhouse": "workspace:*",
"@openint/connector-heron": "workspace:*",
"@openint/connector-hubspot": "workspace:*",
"@openint/connector-lunchmoney": "workspace:*",
Expand Down
Binary file added apps/web/public/_assets/logo-greenhouse.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 24 additions & 0 deletions connectors/connector-greenhouse/def.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import type {ConnectorDef, ConnectorSchemas} from '@openint/cdk'
import {connHelpers} from '@openint/cdk'
import {z} from '@openint/util'

export const greenhouseSchema = {
name: z.literal('greenhouse'),
connectorConfig: z.object({apiKey: z.string()}),
} satisfies ConnectorSchemas

export const greenhouseHelpers = connHelpers(greenhouseSchema)

export const greenhouseDef = {
name: 'greenhouse',
schemas: greenhouseSchema,
metadata: {
displayName: 'greenhouse',
stage: 'beta',
categories: ['ats'],
logoUrl: '/_assets/logo-greenhouse.png',
nangoProvider: 'greenhouse',
},
} satisfies ConnectorDef<typeof greenhouseSchema>

export default greenhouseDef
5 changes: 5 additions & 0 deletions connectors/connector-greenhouse/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
// codegen:start {preset: barrel, include: "./{*.{ts,tsx},*/index.{ts,tsx}}", exclude: "./**/*.{d,spec,test,fixture,gen,node}.{ts,tsx}"}
export * from './def'
export * from './server'
// codegen:end
// export * from '@opensdks/sdk-hubspot'
13 changes: 13 additions & 0 deletions connectors/connector-greenhouse/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"name": "@openint/connector-greenhouse",
"version": "0.0.1",
"private": true,
"module": "./index.ts",
"dependencies": {
"@openint/cdk": "workspace:*",
"@openint/util": "workspace:*",
"@opensdks/runtime": "^0.0.16",
"@opensdks/sdk-greenhouse": "^0.0.1"
},
"devDependencies": {}
}
8 changes: 8 additions & 0 deletions connectors/connector-greenhouse/server.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import type {ConnectorServer} from '@openint/cdk'
import type {greenhouseSchema} from './def'

export const greenhouseServer = {} satisfies ConnectorServer<
typeof greenhouseSchema
>

export default greenhouseServer
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"scripts": {
"web": "pnpm run --filter web dev",
"generate:docs": "pnpm run --filter app-config dev",
"generate:connectorsList": "npx tsx apps/app-config/_generateConnectorLists.ts",
"docs": "cd docs && mintlify dev",
"lint": "eslint --ext .js,.ts,.tsx --cache .",
"mitm": "mitmweb --listen-port 3010 --web-port 3011 --mode reverse:http://localhost:3000",
Expand Down
24 changes: 24 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit da24342

Please sign in to comment.