fern.snippets.get({ ...params }) -> Fern.Snippet[]
-
-
-
Get snippet by endpoint method and path
-
-
-
await fern.snippets.get({ endpoint: { method: Fern.HttpMethod.Get, path: "/v1/search", }, });
-
-
-
request:
Fern.GetSnippetRequest
-
requestOptions:
Snippets.RequestOptions
-
-
fern.snippets.load({ ...params }) -> Fern.SnippetsPage
-
-
-
await fern.snippets.load({ page: 1, orgId: "vellum", apiId: "vellum-ai", sdks: [ { type: "python", package: "vellum-ai", }, ], });
-
-
-
request:
Fern.ListSnippetsRequest
-
requestOptions:
Snippets.RequestOptions
-
-
fern.templates.register({ ...params }) -> void
-
-
-
Store endpoint snippet for a particular SDK.
-
-
-
await fern.templates.register({ orgId: "string", apiId: "string", apiDefinitionId: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", snippet: { sdk: { type: "typescript", package: "string", version: "string", }, endpointId: { path: "string", method: Fern.HttpMethod.Get, identifierOverride: "string", }, snippetTemplate: { type: "v1", clientInstantiation: "string", functionInvocation: { type: "generic", imports: ["string"], isOptional: true, templateString: "string", templateInputs: [ { type: "template", value: { key: "value", }, }, ], inputDelimiter: "string", }, }, additionalTemplates: { string: { type: "v1", clientInstantiation: "string", functionInvocation: { type: "generic", imports: ["string"], isOptional: true, templateString: "string", templateInputs: [ { type: "template", value: { key: "value", }, }, ], inputDelimiter: "string", }, }, }, }, });
-
-
-
request:
Fern.RegisterSnippetTemplateRequest
-
requestOptions:
Templates.RequestOptions
-
-
fern.templates.registerBatch({ ...params }) -> void
-
-
-
Store endpoint snippets for a particular SDK.
-
-
-
await fern.templates.registerBatch({ orgId: "string", apiId: "string", apiDefinitionId: "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32", snippets: [ { sdk: { type: "typescript", package: "string", version: "string", }, endpointId: { path: "string", method: Fern.HttpMethod.Get, identifierOverride: "string", }, snippetTemplate: { type: "v1", clientInstantiation: "string", functionInvocation: { type: "generic", imports: ["string"], isOptional: true, templateString: "string", templateInputs: [ { type: "template", value: { key: "value", }, }, ], inputDelimiter: "string", }, }, additionalTemplates: { string: { type: "v1", clientInstantiation: "string", functionInvocation: { type: "generic", imports: ["string"], isOptional: true, templateString: "string", templateInputs: [ { type: "template", value: { key: "value", }, }, ], inputDelimiter: "string", }, }, }, }, ], });
-
-
-
request:
Fern.RegisterSnippetTemplateBatchRequest
-
requestOptions:
Templates.RequestOptions
-
-
fern.templates.get({ ...params }) -> Fern.EndpointSnippetTemplate
-
-
-
Get the endpoint's snippet template for a particular SDK.
-
-
-
await fern.templates.get({ orgId: "string", apiId: "string", sdk: { type: "typescript", package: "string", version: "string", }, endpointId: { path: "string", method: Fern.HttpMethod.Get, identifierOverride: "string", }, });
-
-
-
request:
Fern.GetSnippetTemplate
-
requestOptions:
Templates.RequestOptions
-
-
fern.tokens.generate({ ...params }) -> Fern.GenerateTokenResponse
-
-
-
Generate a token
-
-
-
await fern.tokens.generate({ orgId: "string", scope: "string", });
-
-
-
request:
Fern.GenerateTokenRequest
-
requestOptions:
Tokens.RequestOptions
-
-
fern.tokens.revoke({ ...params }) -> void
-
-
-
Revoke a token
-
-
-
await fern.tokens.revoke({ orgId: "string", tokenId: "string", });
-
-
-
request:
Fern.RevokeTokenRequest
-
requestOptions:
Tokens.RequestOptions
-
-