@octokit/types
Advanced tools
Comparing version 8.2.0 to 8.2.1
@@ -5,5 +5,5 @@ 'use strict'; | ||
const VERSION = "8.2.0"; | ||
const VERSION = "8.2.1"; | ||
exports.VERSION = VERSION; | ||
//# sourceMappingURL=index.js.map |
@@ -1,1 +0,1 @@ | ||
export const VERSION = "8.2.0"; | ||
export const VERSION = "8.2.1"; |
@@ -9,3 +9,3 @@ import { RequestHeaders } from "./RequestHeaders"; | ||
*/ | ||
export declare type EndpointDefaults = RequestParameters & { | ||
export type EndpointDefaults = RequestParameters & { | ||
baseUrl: Url; | ||
@@ -12,0 +12,0 @@ method: RequestMethod; |
import { RequestMethod } from "./RequestMethod"; | ||
import { Url } from "./Url"; | ||
import { RequestParameters } from "./RequestParameters"; | ||
export declare type EndpointOptions = RequestParameters & { | ||
export type EndpointOptions = RequestParameters & { | ||
method: RequestMethod; | ||
url: Url; | ||
}; |
/** | ||
* Browser's fetch method (or compatible such as fetch-mock) | ||
*/ | ||
export declare type Fetch = any; | ||
export type Fetch = any; |
@@ -1,5 +0,5 @@ | ||
declare type Unwrap<T> = T extends Promise<infer U> ? U : T; | ||
declare type AnyFunction = (...args: any[]) => any; | ||
export declare type GetResponseTypeFromEndpointMethod<T extends AnyFunction> = Unwrap<ReturnType<T>>; | ||
export declare type GetResponseDataTypeFromEndpointMethod<T extends AnyFunction> = Unwrap<ReturnType<T>>["data"]; | ||
type Unwrap<T> = T extends Promise<infer U> ? U : T; | ||
type AnyFunction = (...args: any[]) => any; | ||
export type GetResponseTypeFromEndpointMethod<T extends AnyFunction> = Unwrap<ReturnType<T>>; | ||
export type GetResponseDataTypeFromEndpointMethod<T extends AnyFunction> = Unwrap<ReturnType<T>>["data"]; | ||
export {}; |
import { ResponseHeaders } from "./ResponseHeaders"; | ||
import { Url } from "./Url"; | ||
export declare type OctokitResponse<T, S extends number = number> = { | ||
export type OctokitResponse<T, S extends number = number> = { | ||
headers: ResponseHeaders; | ||
@@ -5,0 +5,0 @@ /** |
@@ -1,2 +0,2 @@ | ||
export declare type RequestError = { | ||
export type RequestError = { | ||
name: string; | ||
@@ -3,0 +3,0 @@ status: number; |
@@ -1,2 +0,2 @@ | ||
export declare type RequestHeaders = { | ||
export type RequestHeaders = { | ||
/** | ||
@@ -3,0 +3,0 @@ * Avoid setting `headers.accept`, use `mediaType.{format|previews}` option instead. |
/** | ||
* HTTP Verb supported by GitHub's REST API | ||
*/ | ||
export declare type RequestMethod = "DELETE" | "GET" | "HEAD" | "PATCH" | "POST" | "PUT"; | ||
export type RequestMethod = "DELETE" | "GET" | "HEAD" | "PATCH" | "POST" | "PUT"; |
@@ -8,3 +8,3 @@ import { RequestHeaders } from "./RequestHeaders"; | ||
*/ | ||
export declare type RequestOptions = { | ||
export type RequestOptions = { | ||
method: RequestMethod; | ||
@@ -11,0 +11,0 @@ url: Url; |
@@ -7,3 +7,3 @@ import { RequestRequestOptions } from "./RequestRequestOptions"; | ||
*/ | ||
export declare type RequestParameters = { | ||
export type RequestParameters = { | ||
/** | ||
@@ -10,0 +10,0 @@ * Base URL to be used when a relative URL is passed, such as `/orgs/{org}`. |
@@ -6,3 +6,3 @@ import { Fetch } from "./Fetch"; | ||
*/ | ||
export declare type RequestRequestOptions = { | ||
export type RequestRequestOptions = { | ||
/** | ||
@@ -9,0 +9,0 @@ * Node only. Useful for custom proxy, certificate, or dns lookup. |
@@ -1,2 +0,2 @@ | ||
export declare type ResponseHeaders = { | ||
export type ResponseHeaders = { | ||
"cache-control"?: string; | ||
@@ -3,0 +3,0 @@ "content-length"?: number; |
/** | ||
* String consisting of an optional HTTP method and relative path or absolute URL. Examples: `'/orgs/{org}'`, `'PUT /orgs/{org}'`, `GET https://example.com/foo/bar` | ||
*/ | ||
export declare type Route = string; | ||
export type Route = string; |
@@ -6,2 +6,2 @@ /** | ||
*/ | ||
export declare type Signal = any; | ||
export type Signal = any; |
/** | ||
* Relative or absolute URL. Examples: `'/orgs/{org}'`, `https://example.com/foo/bar` | ||
*/ | ||
export declare type Url = string; | ||
export type Url = string; |
@@ -1,1 +0,1 @@ | ||
export declare const VERSION = "8.2.0"; | ||
export declare const VERSION = "8.2.1"; |
@@ -1,4 +0,4 @@ | ||
const VERSION = "8.2.0"; | ||
const VERSION = "8.2.1"; | ||
export { VERSION }; | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@octokit/types", | ||
"description": "Shared TypeScript definitions for Octokit projects", | ||
"version": "8.2.0", | ||
"version": "8.2.1", | ||
"license": "MIT", | ||
@@ -13,3 +13,3 @@ "files": [ | ||
"octokit": { | ||
"openapi-version": "10.0.0" | ||
"openapi-version": "8.0.1" | ||
}, | ||
@@ -29,3 +29,3 @@ "main": "dist-node/index.js", | ||
"dependencies": { | ||
"@octokit/openapi-types": "^16.0.0" | ||
"@octokit/openapi-types": "^14.0.0" | ||
}, | ||
@@ -32,0 +32,0 @@ "devDependencies": { |
Sorry, the diff of this file is too big to display
221424
3911
+ Added@octokit/openapi-types@14.0.0(transitive)
- Removed@octokit/openapi-types@16.1.0(transitive)