Milestone 0: import zappier billing, Verae middleware, and Zapier research
Compose-ready workspace: packages/zappier (rate card, portal, Stripe), packages/verae-zapier-middleware (timestamp + NATS), packages/verae-zapier (CLI app), vendor/zapier-platform, and research/zapier vendor corpus. Gate 0 structure checks pass. Product code and research are not yet wired.
This commit is contained in:
commit
b4150c8250
1364 changed files with 6814366 additions and 0 deletions
53
vendor/zapier-platform/packages/schema/lib/schemas/AuthenticationOAuth1ConfigSchema.js
vendored
Normal file
53
vendor/zapier-platform/packages/schema/lib/schemas/AuthenticationOAuth1ConfigSchema.js
vendored
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
'use strict';
|
||||
|
||||
const makeSchema = require('../utils/makeSchema');
|
||||
|
||||
const FunctionSchema = require('./FunctionSchema');
|
||||
const RedirectRequestSchema = require('./RedirectRequestSchema');
|
||||
const RequestSchema = require('./RequestSchema');
|
||||
|
||||
module.exports = makeSchema(
|
||||
{
|
||||
id: '/AuthenticationOAuth1ConfigSchema',
|
||||
description: 'Config for OAuth1 authentication.',
|
||||
type: 'object',
|
||||
required: ['getRequestToken', 'authorizeUrl', 'getAccessToken'],
|
||||
properties: {
|
||||
getRequestToken: {
|
||||
description:
|
||||
'Define where Zapier will acquire a request token which is used for the rest of the three legged authentication process.',
|
||||
oneOf: [{ $ref: RequestSchema.id }, { $ref: FunctionSchema.id }],
|
||||
},
|
||||
authorizeUrl: {
|
||||
description:
|
||||
'Define where Zapier will redirect the user to authorize our app. Typically, you should append an `oauth_token` querystring parameter to the request.',
|
||||
oneOf: [
|
||||
{ $ref: RedirectRequestSchema.id },
|
||||
{ $ref: FunctionSchema.id },
|
||||
],
|
||||
},
|
||||
getAccessToken: {
|
||||
description: 'Define how Zapier fetches an access token from the API',
|
||||
oneOf: [{ $ref: RequestSchema.id }, { $ref: FunctionSchema.id }],
|
||||
},
|
||||
},
|
||||
additionalProperties: false,
|
||||
examples: [
|
||||
{
|
||||
getRequestToken: { require: 'some/path/to/file.js' },
|
||||
authorizeUrl: { require: 'some/path/to/file2.js' },
|
||||
getAccessToken: { require: 'some/path/to/file3.js' },
|
||||
},
|
||||
],
|
||||
antiExamples: [
|
||||
{
|
||||
example: {
|
||||
getRequestToken: { require: 'some/path/to/file.js' },
|
||||
authorizeUrl: { require: 'some/path/to/file2.js' },
|
||||
},
|
||||
reason: 'Missing required key.',
|
||||
},
|
||||
],
|
||||
},
|
||||
[FunctionSchema, RedirectRequestSchema, RequestSchema],
|
||||
);
|
||||
Loading…
Add table
Add a link
Reference in a new issue