Package: tap-totango
tap-totangotap-totangois a Singer tap for theTotango API. It extracts data from the Search API accounts, users, and events endpoints.Built with theMeltano Tap SDKfor Singer Taps.InstallationInstall from PyPi:pipxinstalltap-totangoInstall from BitBucket:pipxinstallgit+https://bitbucket.org/indiciumtech/tap-totango.git@mainConfigurationAccepted Config OptionsA full list of supported settings and capabilities in a reasonably readable form for this tap is available by running:tap-totango--about--format=jsonEach endpoint from theTotango Search APIrequires some parameters with the same name for the query, such asterms,count, andoffset. In these cases, we provide settings namespaced by the stream name (e.g.accounts_terms,users_offset, etc.).settings_group_validation:# An array of arrays listing the minimal valid group of settings required to use the connector--api_url-auth_token-events_terms-events_count-events_offset-accounts_terms-accounts_fields-users_terms-users_fieldssettings:-name:api_urldescription:|The url for the API services.https://api.totango.com is for US services, whereas https://api-eu1.totango.com is for EU services.documentation:https://support.totango.com/hc/en-us/articles/360048132792-Search-API-events-kind:stringvalue:https://api.totango.com-name:auth_tokendescription:|The token to authenticate against the API service.documentation:https://support.totango.com/hc/en-us/articles/203036939-Personal-Access-Token-and-Service-IDkind:password-name:events_termsdescription:|An array containing filter conditions to use for the events stream search.documentation:https://support.totango.com/hc/en-us/articles/360048132792-Search-API-events-kind:arrayvalue:[]-name:events_countdescription:|The maximum number of accounts to return in the events result set.The max. value for count is `1000`.documentation:https://support.totango.com/hc/en-us/articles/360048132792-Search-API-events-kind:integervalue:1000-name:events_offsetdescription:|Page number (0 is the 1st-page).documentation:https://support.totango.com/hc/en-us/articles/360048132792-Search-API-events-kind:integervalue:0-name:account_iddescription:|Filter the events stream results for a specific account.documentation:https://support.totango.com/hc/en-us/articles/360048132792-Search-API-events-kind:string-name:accounts_termsdescription:|An array containing filter conditions to use for the accounts stream search.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:arrayvalue:[]-name:accounts_fieldsdescription:|List of fields to return as results.Note that the account name and account-id are always returned as well.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:arrayvalue:[]-name:accounts_countdescription:|The maximum number of accounts to return in the accounts result set.The max. value for count is 1000.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:integervalue:1000-name:accounts_offsetdescription:|Record number (0 states "start at record 0").The record size can be defined using the count parameter (and limited to 1000).Tip: To page through results, ask for 1000 records (count: 1000). If you receive 1000 records, assume there’s more, in which case you want to pull the next 1000 records (offset: 1000…then 2000…etc.). Repeat paging until the number of records returned is less than 1000.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:integervalue:0-name:accounts_sort_bydescription:|Field name to sort the accounts stream results set by.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:stringvalue:"display_name"-name:accounts_sort_orderdescription:|Order to sort the accounts stream results set by.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:stringvalue:"ASC"-name:users_termsdescription:|An array containing filter conditions to use for the users stream search.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:arrayvalue:[]-name:users_fieldsdescription:|List of fields to return as results.Note that the account name and account-id are always returned as well.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:arrayvalue:[]-name:users_countdescription:|The maximum number of accounts to return in the users result set.The max. value for count is 1000.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:integervalue:1000-name:users_offsetdescription:|Record number (0 states "start at record 0").The record size can be defined using the count parameter (and limited to 1000).Tip: To page through results, ask for 1000 records (count: 1000). If you receive 1000 records, assume there’s more, in which case you want to pull the next 1000 records (offset: 1000…then 2000…etc.). Repeat paging until the number of records returned is less than 1000.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:integervalue:0-name:users_sort_bydescription:|Field name to sort the users stream results set by.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:stringvalue:"display_name"-name:users_sort_orderdescription:|Order to sort the users stream results set by.documentation:https://support.totango.com/hc/en-us/articles/204174135-Search-API-accounts-and-users-kind:stringvalue:"ASC"Configure using environment variablesThis Singer tap will automatically import any environment variables within the working directory's.envif the--config=ENVis provided, such that config values will be considered if a matching
environment variable is set either in the terminal context or in the.envfile.Source Authentication and AuthorizationYou should create aTotango API personal access tokenand provide it as theauth_tokensetting for the tap.We recommend passing it as an environment variable. For instance, when using the tap with Meltano you should add the following line to your.envfile:exportTAP_TOTANGO_AUTH_TOKEN=<YOUR_PERSONAL_ACCESS_TOKEN>UsageYou can easily runtap-totangoby itself or in a pipeline usingMeltano.Executing the Tap Directlytap-totango--version
tap-totango--help
tap-totango--configCONFIG--discover>./catalog.jsonDeveloper ResourcesFollow these instructions to contribute to this project.Initialize your Development Environmentpipxinstallpoetry
poetryinstallCreate and Run TestsCreate tests within thetestssubfolder and
then run:poetryrunpytestYou can also test thetap-totangoCLI interface directly usingpoetry run:poetryruntap-totango--helpTesting withMeltanoNote:This tap will work in any Singer environment and does not require Meltano.
Examples here are for convenience and to streamline end-to-end orchestration scenarios.Next, install Meltano (if you haven't already) and any needed plugins:# Install meltanopipxinstallmeltano# Initialize meltano within this directorycdtap-totango
meltanoinstallNow you can test and orchestrate using Meltano:# Test invocation:meltanoinvoketap-totango--version# OR run a test `elt` pipeline:meltanoelttap-totangotarget-jsonlSDK Dev GuideSee thedev guidefor more instructions on how to use the SDK to
develop your own taps and targets.AcknowledgementsEdson Nogueira thanks all members of the Meltaners group @ Indicium Tech, namely Cesar Rubim, Lucas Marques, Guilherme Tavares e Igor Benincá, for the professional guidance.