Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@friggframework/api-module-42matters

Package Overview
Dependencies
Maintainers
3
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@friggframework/api-module-42matters - npm Package Compare versions

Comparing version 0.0.6-v1-alpha.7 to 0.0.6-v1-alpha-package-update.0

31

api.js

@@ -1,6 +0,5 @@

const { OAuth2Requester } = require('@friggframework/module-plugin');
const { get } = require('@friggframework/assertions');
const { ApiKeyRequester, ModuleConstants, get } = require('@friggframework/core-rollup');
class Api extends OAuth2Requester {
class Api extends ApiKeyRequester {
constructor(params) {

@@ -40,2 +39,28 @@ super(params);

getAuthorizationRequirements() {
return {
url: null,
type: ModuleConstants.authType.apiKey,
data: {
jsonSchema: {
type: 'object',
required: ['access_token'],
properties: {
access_token: {
type: 'string',
title: 'Access Token',
},
},
},
uiSchema: {
clientKey: {
'ui:help':
'To obtain your Access Token, log in to 42Matters Launchpad and click Access Token under API.',
'ui:placeholder': 'Access Token',
},
},
},
};
}
// API METHODS

@@ -42,0 +67,0 @@

4

definition.js

@@ -12,5 +12,3 @@ require('dotenv').config();

requiredAuthMethods: {
getToken: async function(api, params){
return api.setTokens({access_token: api.access_token});
},
setAuthParams: async function(api, params){},
getEntityDetails: async function(api, callbackParams, tokenResponse, userId) {

@@ -17,0 +15,0 @@ return {

@@ -1,2 +0,2 @@

const { globalSetup } = require('@friggframework/test-environment');
const { globalSetup } = require('@friggframework/core-rollup');
module.exports = globalSetup;

@@ -1,2 +0,2 @@

const { globalTeardown } = require('@friggframework/test-environment');
const { globalTeardown } = require('@friggframework/core-rollup');
module.exports = globalTeardown;
{
"name": "@friggframework/api-module-42matters",
"version": "0.0.6-v1-alpha.7",
"version": "0.0.6-v1-alpha-package-update.0",
"prettier": "@friggframework/prettier-config",

@@ -14,7 +14,2 @@ "description": "",

"devDependencies": {
"@friggframework/assertions": "^1.0.22-v1-alpha.6",
"@friggframework/eslint-config": "^1.0.21-v1-alpha.4",
"@friggframework/logs": "^1.0.24-v1-alpha.4",
"@friggframework/module-plugin": "^1.1.16-v1-alpha.7",
"@friggframework/test-environment": "^1.1.21-v1-alpha.4",
"dotenv": "^16.3.1",

@@ -30,5 +25,6 @@ "eslint": "^8.49.0",

"dependencies": {
"@friggframework/core": "^0.2.0",
"md5": "^2.3.0"
},
"gitHead": "b5ae7333eb660a8014a7c27a08b5c8cb1938ff1c"
"gitHead": "741dafe34c2d0187e9942ce655437c63a8a0943b"
}
require('dotenv').config();
const { Api } = require('../api');
const Authenticator = require("@friggframework/test-environment/Authenticator");

@@ -5,0 +4,0 @@ describe('42matters API Tests', () => {

@@ -0,9 +1,18 @@

const { connectToDatabase, disconnectFromDatabase, createObjectId, Auther } = require('@friggframework/core-rollup');
//require('dotenv').config();
const { Definition} = require('../definition');
const { Auther } = require('@friggframework/module-plugin');
const {connectToDatabase, disconnectFromDatabase, createObjectId} = require('@friggframework/database/mongo');
const { Authenticator, testDefinition } = require("@friggframework/test-environment");
const {
testDefinitionRequiredAuthMethods,
testAutherDefinition
} = require("@friggframework/test-environment");
describe('42matters Auther Tests', () => {
let auther, authUrl;
const mocks = {
getAccountStatus: {
status: 'active',
}
}
testAutherDefinition(Definition, mocks)
describe('42matters Module Live Tests', () => {
let auther;
beforeAll(async () => {

@@ -35,5 +44,5 @@ await connectToDatabase();

});
it('Should test the Definition methods', async () => {
await testDefinition(auther.api, Definition,undefined,undefined,auther.userId);
})
it('Should test the Definition methods individually', async () => {
await testDefinitionRequiredAuthMethods(auther.api, Definition,undefined,undefined,auther.userId);
});
});

@@ -40,0 +49,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc