@octokit/auth-app
Advanced tools
Comparing version 2.1.3 to 2.2.0
@@ -262,3 +262,3 @@ 'use strict'; | ||
const VERSION = '2.1.3'; | ||
const VERSION = '2.2.0'; | ||
@@ -265,0 +265,0 @@ function createAppAuth(options) { |
@@ -1,1 +0,1 @@ | ||
export const VERSION = '2.1.3'; | ||
export const VERSION = '2.2.0'; |
@@ -1,2 +0,2 @@ | ||
import { Request, InstallationAuthOptions, StrategyOptionsWithDefaults } from "./types"; | ||
export declare function getInstallationAuthentication(state: StrategyOptionsWithDefaults, options: InstallationAuthOptions, customRequest?: Request): Promise<import("./types").InstallationAccessTokenAuthentication>; | ||
import { RequestInterface, InstallationAuthOptions, StrategyOptionsWithDefaults } from "./types"; | ||
export declare function getInstallationAuthentication(state: StrategyOptionsWithDefaults, options: InstallationAuthOptions, customRequest?: RequestInterface): Promise<import("./types").InstallationAccessTokenAuthentication>; |
@@ -1,2 +0,2 @@ | ||
import { Request, OAuthOptions, StrategyOptionsWithDefaults, OAuthAccesTokenAuthentication } from "./types"; | ||
export declare function getOAuthAuthentication(state: StrategyOptionsWithDefaults, options: OAuthOptions, customRequest?: Request): Promise<OAuthAccesTokenAuthentication>; | ||
import { RequestInterface, OAuthOptions, StrategyOptionsWithDefaults, OAuthAccesTokenAuthentication } from "./types"; | ||
export declare function getOAuthAuthentication(state: StrategyOptionsWithDefaults, options: OAuthOptions, customRequest?: RequestInterface): Promise<OAuthAccesTokenAuthentication>; |
@@ -1,2 +0,2 @@ | ||
import { AnyResponse, Endpoint, Parameters, Request, Route, State } from "./types"; | ||
export declare function hook(state: State, request: Request, route: Route | Endpoint, parameters?: Parameters): Promise<AnyResponse>; | ||
import { AnyResponse, EndpointOptions, RequestParameters, RequestInterface, Route, State } from "./types"; | ||
export declare function hook(state: State, request: RequestInterface, route: Route | EndpointOptions, parameters?: RequestParameters): Promise<AnyResponse>; |
@@ -8,3 +8,3 @@ import { StrategyOptions } from "./types"; | ||
}>) & { | ||
hook: (request: import("@octokit/request/dist-types/types").request, route: string | import("./types").Endpoint, parameters?: import("./types").Parameters | undefined) => Promise<import("./types").OctokitResponse<any>>; | ||
hook: (request: import("@octokit/types").RequestInterface, route: string | import("@octokit/types").EndpointOptions, parameters?: import("@octokit/types").RequestParameters | undefined) => Promise<import("@octokit/types").OctokitResponse<any>>; | ||
}; |
@@ -1,1 +0,1 @@ | ||
export declare function requiresAppAuth(url: string): Boolean; | ||
export declare function requiresAppAuth(url: string | undefined): Boolean; |
@@ -1,4 +0,9 @@ | ||
/// <reference types="node" /> | ||
import * as OctokitTypes from "@octokit/types"; | ||
import LRUCache from "lru-cache"; | ||
import { request } from "@octokit/request"; | ||
export declare type AnyResponse = OctokitTypes.OctokitResponse<any>; | ||
export declare type EndpointDefaults = OctokitTypes.EndpointDefaults; | ||
export declare type EndpointOptions = OctokitTypes.EndpointOptions; | ||
export declare type RequestParameters = OctokitTypes.RequestParameters; | ||
export declare type Route = OctokitTypes.Route; | ||
export declare type RequestInterface = OctokitTypes.RequestInterface; | ||
export declare type Cache = LRUCache<string, string> | { | ||
@@ -54,7 +59,7 @@ get: (key: string) => string; | ||
clientSecret?: string; | ||
request?: typeof request; | ||
request?: OctokitTypes.RequestInterface; | ||
cache?: Cache; | ||
}; | ||
export declare type StrategyOptionsWithDefaults = StrategyOptions & { | ||
request: typeof request; | ||
request: OctokitTypes.RequestInterface; | ||
cache: Cache; | ||
@@ -83,120 +88,5 @@ }; | ||
export declare type State = StrategyOptions & { | ||
request: typeof request; | ||
request: OctokitTypes.RequestInterface; | ||
cache: Cache; | ||
}; | ||
export declare type Request = typeof request; | ||
import { Agent } from "http"; | ||
export declare type Fetch = any; | ||
export declare type Signal = any; | ||
export declare type Endpoint = Parameters & { | ||
method: Method; | ||
url: Url; | ||
}; | ||
export declare type Method = "DELETE" | "GET" | "HEAD" | "PATCH" | "POST" | "PUT"; | ||
export declare type Route = string; | ||
export declare type Url = string; | ||
export declare type Parameters = { | ||
/** | ||
* Base URL to be used when a relative URL is passed, such as `/orgs/:org`. | ||
* If `baseUrl` is `https://enterprise.acme-inc.com/api/v3`, then the request | ||
* will be sent to `https://enterprise.acme-inc.com/api/v3/orgs/:org`. | ||
*/ | ||
baseUrl?: string; | ||
/** | ||
* HTTP headers. Use lowercase keys. | ||
*/ | ||
headers?: RequestHeaders; | ||
/** | ||
* Media type options, see {@link https://developer.github.com/v3/media/|GitHub Developer Guide} | ||
*/ | ||
mediaType?: { | ||
/** | ||
* `json` by default. Can be `raw`, `text`, `html`, `full`, `diff`, `patch`, `sha`, `base64`. Depending on endpoint | ||
*/ | ||
format?: string; | ||
/** | ||
* Custom media type names of {@link https://developer.github.com/v3/media/|API Previews} without the `-preview` suffix. | ||
* Example for single preview: `['squirrel-girl']`. | ||
* Example for multiple previews: `['squirrel-girl', 'mister-fantastic']`. | ||
*/ | ||
previews?: string[]; | ||
}; | ||
/** | ||
* Pass custom meta information for the request. The `request` object will be returned as is. | ||
*/ | ||
request?: OctokitRequestOptions; | ||
/** | ||
* Any additional parameter will be passed as follows | ||
* 1. URL parameter if `':parameter'` or `{parameter}` is part of `url` | ||
* 2. Query parameter if `method` is `'GET'` or `'HEAD'` | ||
* 3. Request body if `parameter` is `'data'` | ||
* 4. JSON in the request body in the form of `body[parameter]` unless `parameter` key is `'data'` | ||
*/ | ||
[parameter: string]: any; | ||
}; | ||
export declare type OctokitRequestOptions = { | ||
/** | ||
* Node only. Useful for custom proxy, certificate, or dns lookup. | ||
*/ | ||
agent?: Agent; | ||
/** | ||
* Custom replacement for built-in fetch method. Useful for testing or request hooks. | ||
*/ | ||
fetch?: Fetch; | ||
/** | ||
* Use an `AbortController` instance to cancel a request. In node you can only cancel streamed requests. | ||
*/ | ||
signal?: Signal; | ||
/** | ||
* Node only. Request/response timeout in ms, it resets on redirect. 0 to disable (OS limit applies). `options.request.signal` is recommended instead. | ||
*/ | ||
timeout?: number; | ||
[option: string]: any; | ||
}; | ||
export declare type RequestHeaders = { | ||
/** | ||
* Avoid setting `accept`, use `mediaFormat.{format|previews}` instead. | ||
*/ | ||
accept?: string; | ||
/** | ||
* Use `authorization` to send authenticated request, remember `token ` / `bearer ` prefixes. Example: `token 1234567890abcdef1234567890abcdef12345678` | ||
*/ | ||
authorization?: string; | ||
/** | ||
* `user-agent` is set do a default and can be overwritten as needed. | ||
*/ | ||
"user-agent"?: string; | ||
[header: string]: string | number | undefined; | ||
}; | ||
export declare type ResponseHeaders = { | ||
[header: string]: string; | ||
}; | ||
export declare type OctokitResponse<T> = { | ||
headers: ResponseHeaders; | ||
/** | ||
* http response code | ||
*/ | ||
status: number; | ||
/** | ||
* URL of response after all redirects | ||
*/ | ||
url: string; | ||
/** | ||
* This is the data you would see in https://developer.Octokit.com/v3/ | ||
*/ | ||
data: T; | ||
}; | ||
export declare type AnyResponse = OctokitResponse<any>; | ||
export declare type Defaults = Parameters & { | ||
method: Method; | ||
baseUrl: string; | ||
headers: RequestHeaders & { | ||
accept: string; | ||
"user-agent": string; | ||
}; | ||
mediaType: { | ||
format: string; | ||
previews: string[]; | ||
}; | ||
}; | ||
export {}; |
@@ -1,1 +0,1 @@ | ||
export declare const VERSION = "2.1.3"; | ||
export declare const VERSION = "2.2.0"; |
@@ -237,3 +237,3 @@ import { getUserAgent } from 'universal-user-agent'; | ||
const VERSION = '2.1.3'; | ||
const VERSION = '2.2.0'; | ||
@@ -240,0 +240,0 @@ function createAppAuth(options) { |
{ | ||
"name": "@octokit/auth-app", | ||
"description": "GitHub App authentication for JavaScript", | ||
"version": "2.1.3", | ||
"version": "2.2.0", | ||
"license": "MIT", | ||
@@ -24,3 +24,4 @@ "files": [ | ||
"dependencies": { | ||
"@octokit/request": "^5.0.2", | ||
"@octokit/request": "^5.3.0", | ||
"@octokit/types": "^1.0.0", | ||
"@types/lru-cache": "^5.1.0", | ||
@@ -33,5 +34,5 @@ "lru-cache": "^5.1.1", | ||
"@pika/pack": "^0.5.0", | ||
"@pika/plugin-build-node": "^0.6.0", | ||
"@pika/plugin-build-web": "^0.6.0", | ||
"@pika/plugin-ts-standard-pkg": "^0.6.0", | ||
"@pika/plugin-build-node": "^0.7.0", | ||
"@pika/plugin-build-web": "^0.7.0", | ||
"@pika/plugin-ts-standard-pkg": "^0.7.0", | ||
"@types/fetch-mock": "^7.3.1", | ||
@@ -54,3 +55,3 @@ "@types/jest": "^24.0.13", | ||
"main": "dist-node/index.js", | ||
"module": "dist-web/index.js" | ||
"deno": "dist-web/index.js" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
86482
6
869
+ Added@octokit/types@^1.0.0
+ Added@octokit/types@1.1.0(transitive)
+ Added@types/node@12.20.55(transitive)
- Removed@types/node@22.7.9(transitive)
- Removedundici-types@6.19.8(transitive)
Updated@octokit/request@^5.3.0