Submodules

airbyte_cdk.sources.streams.http.auth.core module

class airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator(*args, **kwargs)

Bases: abc.ABC

Base abstract class for various HTTP Authentication strategies. Authentication strategies are generally expected to provide security credentials via HTTP headers.

abstract get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

class airbyte_cdk.sources.streams.http.auth.core.NoAuth(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

airbyte_cdk.sources.streams.http.auth.oauth module

class airbyte_cdk.sources.streams.http.auth.oauth.Oauth2Authenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

Generates OAuth2.0 access tokens from an OAuth2.0 refresh token and client credentials. The generated access token is attached to each request via the Authorization header.

get_access_token()
get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

get_refresh_access_token_headers()
get_refresh_request_body() Mapping[str, Any]

Override to define additional parameters

refresh_access_token() Tuple[str, int]

returns a tuple of (access_token, token_lifespan_in_seconds)

token_has_expired() bool

airbyte_cdk.sources.streams.http.auth.token module

class airbyte_cdk.sources.streams.http.auth.token.BasicHttpAuthenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.token.TokenAuthenticator

Builds auth based off the basic authentication scheme as defined by RFC 7617, which transmits credentials as USER ID/password pairs, encoded using bas64 https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication#basic_authentication_scheme

class airbyte_cdk.sources.streams.http.auth.token.MultipleTokenAuthenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

class airbyte_cdk.sources.streams.http.auth.token.TokenAuthenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

Module contents

class airbyte_cdk.sources.streams.http.auth.BasicHttpAuthenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.token.TokenAuthenticator

Builds auth based off the basic authentication scheme as defined by RFC 7617, which transmits credentials as USER ID/password pairs, encoded using bas64 https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication#basic_authentication_scheme

class airbyte_cdk.sources.streams.http.auth.HttpAuthenticator(*args, **kwargs)

Bases: abc.ABC

Base abstract class for various HTTP Authentication strategies. Authentication strategies are generally expected to provide security credentials via HTTP headers.

abstract get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

class airbyte_cdk.sources.streams.http.auth.MultipleTokenAuthenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

class airbyte_cdk.sources.streams.http.auth.NoAuth(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

class airbyte_cdk.sources.streams.http.auth.Oauth2Authenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

Generates OAuth2.0 access tokens from an OAuth2.0 refresh token and client credentials. The generated access token is attached to each request via the Authorization header.

get_access_token()
get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.

get_refresh_access_token_headers()
get_refresh_request_body() Mapping[str, Any]

Override to define additional parameters

refresh_access_token() Tuple[str, int]

returns a tuple of (access_token, token_lifespan_in_seconds)

token_has_expired() bool
class airbyte_cdk.sources.streams.http.auth.TokenAuthenticator(*args, **kwargs)

Bases: airbyte_cdk.sources.streams.http.auth.core.HttpAuthenticator

get_auth_header() Mapping[str, Any]
Returns

A dictionary containing all the necessary headers to authenticate.