Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@myinterview/global-api-sdk
Advanced tools
You can see the full typed documentation here.
This project requires NodeJS (version 8 or later) and NPM. Node and NPM are really easy to install. To make sure you have them available on your machine, try running the following command.
$ npm -v && node -v
6.4.1
v8.16.0
npm i @myinterview/global-api-sdk
import { GlobalApi } from '@myinterview/global-api-sdk';
GlobalApi.setConfig({
secret: 'yoursecret',
companyId: 'yourcompanyid',
accessKey: 'youraccesskey',
});
To use the SDK you have to set the configuration with the keys provided by myinterview prior use of the classes.
This call will populate the headers you need to connect to the global API service it will return an object that you can use in you request.
import { GlobalApi } from '@myinterview/global-api-sdk';
GlobalApi.populateHeaders({
secret: 'yoursecret',
companyId: 'yourcompanyid',
accessKey: 'youraccesskey',
});
It will return:
{
'x-myinterview-timestamp': 'headTimestamp',
'x-myinterview-key': 'headKey',
'x-myinterview-signed': 'headSigned'
}
interface IApiResponseObj<T = any> {
statusCode: number;
errorCode: number;
statusReason: string;
callId: string;
data?: T;
time: Date | number;
}
This is the response object you will receive from the SDK the content of data will change based on your request.
interface IApiErrorObj {
errorMessage: string | ValidationError[];
errorDetails?: string;
statusCode: number;
errorCode: number;
statusReason: string;
callId?: string;
time: Date | number;
}
This is the error response object you will receive from the SDK.
import { GACandidates } from '@myinterview/global-api-sdk';
interface IBody {
job_id?: string;
communication?: boolean;
deadlineDate?: Date | string | number;
timezoneForInvite?: string;
candidates: {
username?: string;
email: string;
phone?: string;
status?: string;
reminders?: {
Content: string;
companyName: string;
greetings?: string;
isSent: boolean;
reminderDate: Date | string;
timezone: string;
}[];
type?: string;
candidate_id?: string;
apiKey?: string;
jobTitle?: string;
urlStart?: string;
}[];
};
await GACandidates.createBulkCandidates(body);
This call will create one or more candidates and connect them to your Job.
interface IBody {
id: string; // You have to provide the id of the candidate
status?: string;
username?: string;
deadline?: string | Date | number;
timezoneForInvite?: string;
location?: string;
};
await GACandidates.updateCandidate(body);
import { GACompanies } from '@myinterview/global-api-sdk';
const res: IApiResponseObj<ICompany> = await GACompanies.getCompanyInfo();
const companyInfo = res.data;
const res: IApiResponseObj<ITemplate[]> = await GACompanies.getCompanyTemplates();
const templates = res.data;
interface IBody {
id?: string | number;
hideQuestions?: boolean;
name: string;
questions: {
numOfRetakes: number;
partDuration: number;
question: string;
timeLimit?: number;
videoQuestion?: string;
}[];
intoductionURL?: string;
}[]
await GACompanies.createCompanyTemplateBulk(body);
import { GAJobs } from '@myinterview/global-api-sdk';
const res: IApiResponseObj<IJob[]> = await GAJobs.getJobs();
const jobs = res.data;
const ids: string[];
const res: IApiResponseObj<IJob[]> = await GAJobs.getJobsWithIds(ids);
const jobs = res.data;
const id: string;
const res: IApiResponseObj<IJob> = await GAJobs.getJob(id);
const job = res.data;
interface IBody {
title: string;
language?: string;
overlay?: string;
termsUrl?: string;
privacyUrl?: string;
backgroundImage?: string;
transcriptLanguage?: string;
config?: IJobConfig;
deadlineDate?: string | Date | number;
experience?: string;
jobDescription?: string;
logo?: string;
url?: string;
questions?: IQuestion[];
reminderValues?: string[];
skills?: string[];
introVideo?: string;
}
await GAJobs.createJob(body);
interface IBody {
job_id: string; // REQUIRED !
language?: string;
overlay?: string;
termsUrl?: string;
privacyUrl?: string;
backgroundImage?: string;
transcriptLanguage?: string;
title?: string;
slug?: string;
config?: IJobConfig;
deadlineDate?: string | Date | number;
experience?: string;
jobDescription?: string;
logo?: string;
url?: string;
questions?: IQuestion[];
reminderValues?: string[];
skills?: string[];
kanban?: IJobKanban[];
permissions?: IJobPermission[];
introVideo?: string;
archived?: boolean;
api_created?: string;
location?: string;
}
await GAJobs.updateJob(body);
import { GAVideos } from '@myinterview/global-api-sdk';
const id: string;
const res: IApiResponseObj<IVideo> = await GAVideos.getVideo(id);
const video = res.data;
const id: string;
const res: IApiResponseObj<IPersonality> = await GAVideos.getVideoPersonality(id);
const personality = res.data;
FAQs
SDK to access myInterview Global API
The npm package @myinterview/global-api-sdk receives a total of 0 weekly downloads. As such, @myinterview/global-api-sdk popularity was classified as not popular.
We found that @myinterview/global-api-sdk demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 7 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.