{"id":20204580,"url":"https://github.com/wilsonsilva/tide-api","last_synced_at":"2025-04-10T12:12:44.511Z","repository":{"id":59159142,"uuid":"188682218","full_name":"wilsonsilva/tide-api","owner":"wilsonsilva","description":"Client for Tide's bank RESTful API","archived":false,"fork":false,"pushed_at":"2020-06-08T20:16:22.000Z","size":56,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-04-10T08:55:48.461Z","etag":null,"topics":["accounts","api","api-client","bank","companies","rest","rest-api","tide","transactions"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wilsonsilva.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-05-26T12:48:49.000Z","updated_at":"2020-06-22T13:00:46.000Z","dependencies_parsed_at":"2022-09-13T20:11:15.429Z","dependency_job_id":null,"html_url":"https://github.com/wilsonsilva/tide-api","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wilsonsilva%2Ftide-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wilsonsilva%2Ftide-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wilsonsilva%2Ftide-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wilsonsilva%2Ftide-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wilsonsilva","download_url":"https://codeload.github.com/wilsonsilva/tide-api/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248217080,"owners_count":21066633,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["accounts","api","api-client","bank","companies","rest","rest-api","tide","transactions"],"created_at":"2024-11-14T05:14:00.334Z","updated_at":"2025-04-10T12:12:44.490Z","avatar_url":"https://github.com/wilsonsilva.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Tide::API\n\n[![Gem Version](https://badge.fury.io/rb/tide-api.svg)](https://badge.fury.io/rb/tide-api)\n[![Build Status](https://travis-ci.org/wilsonsilva/tide-api.svg?branch=master)](https://travis-ci.org/wilsonsilva/tide-api)\n[![Maintainability](https://api.codeclimate.com/v1/badges/15feb9e5e8d4faeb9921/maintainability)](https://codeclimate.com/github/wilsonsilva/tide-api/maintainability)\n[![Test Coverage](https://api.codeclimate.com/v1/badges/15feb9e5e8d4faeb9921/test_coverage)](https://codeclimate.com/github/wilsonsilva/tide-api/test_coverage)\n[![Security](https://hakiri.io/github/wilsonsilva/tide-api/master.svg)](https://hakiri.io/github/wilsonsilva/tide-api/master)\n[![Inline docs](http://inch-ci.org/github/wilsonsilva/tide-api.svg?branch=master)](http://inch-ci.org/github/wilsonsilva/tide-api)\n\nRuby interface to Tide's bank RESTful API.\n\n## Table of contents\n- [Installation](#installation)\n- [Usage](#usage)\n  - [Authentication](#authentication)\n  - [Obtaining an Authorization Grant Code](#obtaining-an-azuthorization-grant-code)\n  - [Exchanging an Authorisation Grant for an Access Token](#exchanging-an-authorisation-grant-for-an-access-token)\n  - [Fetching Companies](#fetching-companies)\n  - [Fetching Accounts](#fetching-accounts)\n  - [Fetching Transactions](#fetching-transactions)\n- [Development](#development)\n- [Contributing](#contributing)\n- [License](#license)\n- [Code of Conduct](#code-of-conduct)\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'tide-api'\n```\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install tide-api\n\n## Usage\n\n### Authentication\n\nTide uses `Access Tokens` to allow access to the API via OAuth 2. Tide uses `Access Token`s to allow access to the\nAPI via OAuth 2. You can obtain an OAuth 2 `Access Toke`n by navigating to the below url, either in the web application\nor through an in-app browser window:\n\n`https://api.tide.co/tide-backend/oauth/index.html?redirect_url={url}\u0026client_id={unique_id}`\n\n| Parameter | Type | Description |\n| --- | --- | --- |\n| `redirect_uri` | string | Fully qualified URL to which `Authorisation Grants` will be delivered to. Grants will be delivered only on successful authorisation by resource owner. |\n| `client_id` | string | Unique identifier for the requester. |\n\nOnce the page loads, the user needs to enter the unique email address, which is registered on their Tide account.\n\n### Obtaining an Authorization Grant Code\nUse the bundled minimalistic AuthServer to automate the process above:\n\n```ruby\nrequire 'tide/api'\nrequire 'tide/api/auth_server'\n\nserver = Tide::API::AuthServer.new\nauth_grant_code = server.run\n```\n\n`Authorisation Grants` can only be used once off by the client, once used they are expired and cannot be used to issue\nnew `Access Tokens`.\n\n### Exchanging an Authorisation Grant for an Access Token\nExchange the authorisation grant code with the method `fetch_tokens`:\n\n```ruby\nclient = Tide::API::Client.new\ntokens = client.fetch_tokens(auth_grant_code)\n\n# Tokens contains an access token and a refresh token\ntokens.access_token\ntokens.refresh_token\n````\n\nThe method `fetch_tokens` will configure the client behind the scenes to make authenticated requests.\n\n### Fetching Companies\nThis method retrieves a collection of companies with the user. The user is determined from authorization header.\n\n```ruby\ncompanies = client.fetch_companies\n````\n\n### Fetching Accounts\nThis method retrieves a collection of company accounts associated with the user. The user is determined from\nauthorization header.\n\n```ruby\naccounts = client.fetch_accounts(companies.first.id)\n````\n\n### Fetching Transactions\nThis method retrieves a collection of an account's transactions:\n\n```ruby\ntransactions = client.fetch_transactions(accounts.first.id)\n```\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies, configure git hooks and create support files.\n\nYou can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nThe health and maintainability of the codebase is ensured through a set of\nRake tasks to test, lint and audit the gem for security vulnerabilities and documentation:\n\n```\nrake bundle:audit          # Checks for vulnerable versions of gems \nrake qa                    # Test, lint and perform security and documentation audits\nrake rubocop               # Lint the codebase with RuboCop\nrake rubocop:auto_correct  # Auto-correct RuboCop offenses\nrake spec                  # Run RSpec code examples\nrake verify_measurements   # Verify that yardstick coverage is at least 100%\nrake yard                  # Generate YARD Documentation\nrake yard:junk             # Check the junk in your YARD Documentation\nrake yardstick_measure     # Measure docs in lib/**/*.rb with yardstick\n```\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/wilsonsilva/tide-api.\nThis project is intended to be a safe, welcoming space for collaboration, and contributors are expected\nto adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).\n\n## Code of Conduct\n\nEveryone interacting in the Tide::API project’s codebases, issue trackers, chat rooms and mailing lists\nis expected to follow the [code of conduct](https://github.com/wilsonsilva/tide-api/blob/master/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilsonsilva%2Ftide-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwilsonsilva%2Ftide-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilsonsilva%2Ftide-api/lists"}