Skip to content

Interface: MultiQueryParamTokenAuthentication

core.MultiQueryParamTokenAuthentication

Authenticate using multiple tokens, each passed as a different URL parameter, e.g. https://example.com/api?param1=token1&param2=token2.

The parameter names are defined in the params array property.

Example

pack.setUserAuthentication({
  type: coda.AuthenticationType.MultiQueryParamToken,
  params: [
    { name: "key", description: "The key." },
    { name: "secret", description: "The secret." },
  ],
});

See

Hierarchy

MultiQueryParamTokenAuthentication

Properties

endpointDomain

Optional endpointDomain: string

When requiresEndpointUrl is set to true this should be the root domain that all endpoints share. For example, this value would be "example.com" if specific endpoints looked like {custom-subdomain}.example.com.

For packs that make requests to multiple domains (uncommon), this should be the domain within networkDomains that this configuration applies to.

Inherited from

BaseAuthentication.endpointDomain

Defined in

types.ts:284


getConnectionName

Optional getConnectionName: MetadataFormula

A function that is called when a user sets up a new account, that returns a name for the account to label that account in the UI. The users credentials are applied to any fetcher requests that this function makes. Typically, this function makes an API call to an API's "who am I" endpoint and returns a username.

If omitted, or if the function returns an empty value, the account will be labeled with the creating user's Coda username.

Inherited from

BaseAuthentication.getConnectionName

Defined in

types.ts:252


instructionsUrl

Optional instructionsUrl: string

A link to a help article or other page with more instructions about how to set up an account for this pack.

Inherited from

BaseAuthentication.instructionsUrl

Defined in

types.ts:267


networkDomain

Optional networkDomain: string | string[]

Which domain(s) should get auth credentials, when a pack is configured with multiple domains. Packs configured with only one domain or with requiresEndpointUrl set to true can omit this.

Using multiple authenticated network domains is uncommon and requires Coda approval.

Inherited from

BaseAuthentication.networkDomain

Defined in

types.ts:298


params

params: { description: string ; name: string }[]

Names and descriptions of the query parameters used for authentication.

Defined in

types.ts:479


postSetup

Optional postSetup: SetEndpoint[]

One or more setup steps to run after the user has set up the account, before completing installation of the pack. This is not common.

Inherited from

BaseAuthentication.postSetup

Defined in

types.ts:290


requiresEndpointUrl

Optional requiresEndpointUrl: boolean

If true, indicates this has pack has a specific endpoint domain for each account, that is used as the basis of HTTP requests. For example, API requests are made to .example.com rather than example.com. If true, the user will be prompted to provide their specific endpoint domain when creating a new account.

Inherited from

BaseAuthentication.requiresEndpointUrl

Defined in

types.ts:275


type

type: MultiQueryParamToken

Identifies this as MultiQueryParamToken authentication.

Defined in

types.ts:475