ADK for TypeScript: API Reference
    Preparing search index...

    Function credentialToParam

    • Converts a scheme and credential into the tool parameter that carries the credential, plus the value to send for it.

      Service-account, OAuth2, and OpenID Connect credentials reach this function already exchanged for a bearer token, so they take the HTTP branch.

      Parameters

      Returns [ApiParameter | undefined, Record<string, string> | undefined]

      A [parameter, values] pair, both undefined when the credential carries nothing to send.

      Error For basic authentication, which is not supported, and for a scheme and credential combination that cannot be expressed as a parameter.