{"id":26358279,"url":"https://github.com/spoje-net/csas-authorize","last_synced_at":"2025-03-16T14:27:35.162Z","repository":{"id":278376401,"uuid":"932287994","full_name":"Spoje-NET/csas-authorize","owner":"Spoje-NET","description":"Obtain Access Key from CSAS/Erste","archived":false,"fork":false,"pushed_at":"2025-03-14T12:27:46.000Z","size":748,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-14T13:31:52.677Z","etag":null,"topics":["api-key-authentication","fintech"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Spoje-NET.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-02-13T17:11:01.000Z","updated_at":"2025-03-14T12:27:49.000Z","dependencies_parsed_at":"2025-03-14T13:27:57.438Z","dependency_job_id":"733049b6-9a58-43a8-8cde-2fd2720f5995","html_url":"https://github.com/Spoje-NET/csas-authorize","commit_stats":null,"previous_names":["spoje-net/csas-authorize"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Spoje-NET%2Fcsas-authorize","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Spoje-NET%2Fcsas-authorize/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Spoje-NET%2Fcsas-authorize/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Spoje-NET%2Fcsas-authorize/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Spoje-NET","download_url":"https://codeload.github.com/Spoje-NET/csas-authorize/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243881116,"owners_count":20362901,"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":["api-key-authentication","fintech"],"created_at":"2025-03-16T14:27:34.601Z","updated_at":"2025-03-16T14:27:35.157Z","avatar_url":"https://github.com/Spoje-NET.png","language":"PHP","readme":"![CSAS Auhorize Logo](src/images/csas-authorize.svg?raw=true)\n\n# CSAS Authorize\n\nThis application provides a simple way to authorize your application with CSAS API.\n\n## Installation\n\n```bash\nsudo apt install lsb-release wget apt-transport-https bzip2\n\n\nwget -qO- https://repo.vitexsoftware.com/keyring.gpg | sudo tee /etc/apt/trusted.gpg.d/vitexsoftware.gpg\necho \"deb [signed-by=/etc/apt/trusted.gpg.d/vitexsoftware.gpg]  https://repo.vitexsoftware.com  $(lsb_release -sc) main\" | sudo tee /etc/apt/sources.list.d/vitexsoftware.list\nsudo apt update\n\nsudo apt install csas-authorize\n```\n\n## Usage\n1. Register your application at [CSAS Developer Portal](https://developers.csas.cz/)\n2. Create new application and get your `client_id` and `client_secret`\n3. Open in browser `csas-authorize` and fill in your `client_id` and `client_secret`\n4. Open your browser and authorize your application\n\n\n!['Apps'](apps-screenshot.png?raw=true)\nMain screen with list of your applications registered at CSAS Developer Portal\n\n\n![App](app-screenshot.png?raw=true)\nOne application can have multiple tokens\n\n!['Token'](token-screenshot.png?raw=true)\nOnce is token created you can see it's details. Each Refresh Token can have multiple Access Tokens.\nRefresh token is valid for 180 days and Access Token for 5 minutes.\n\n## Command line usage\n\n```shell\nUsage: php csas-access-token --tokenId=\u003cTOKEN_ID\u003e [--output=\u003cOUTPUT_FILE\u003e] [--environment=\u003cENVIRONMENT\u003e] [--list]\nOptions:\n  --tokenId, -t        The token ID (required)\n  --output, -o         The output file (optional)\n  --environment, -e    The environment file with DB_* fields (optional)\n  --list, -l           List available tokens (optional)\n  --accesTokenKey, -a  Specify custom Access Token key instead of ACCESS_TOKEN\n  --sandboxModeKey, -s Specify custom SandBox Mode key instead of SANDBOX_MODE\n\nExample:  csas-access-token -t71004963-e3d4-471f-96fc-1aef79d17ec1 -aCSAS_TOKEN -o.env\n```\n\nIf there is no output file specified, the access token is printed to the standard output.\n\n\n## Development\n\nWe use two SQL tables to store data. For production we use MariaDB and for development we use SQLite.\n\n### Table `application`\n\n\u003cpre\u003e\n+--------------------------+------------------+------+-----+---------------------+-------------------------------+\n| Field                    | Type             | Null | Key | Default             | Extra                         |\n+--------------------------+------------------+------+-----+---------------------+-------------------------------+\n| id                       | int(11) unsigned | NO   | PRI | NULL                | auto_increment                |\n| uuid                     | char(36)         | YES  |     | NULL                |                               |\n| name                     | varchar(255)     | YES  |     | NULL                |                               |\n| logo                     | varchar(255)     | YES  |     | NULL                |                               |\n| sandbox_client_id        | char(36)         | YES  |     | NULL                |                               |\n| sandbox_client_secret    | varchar(255)     | YES  |     | NULL                |                               |\n| sandbox_redirect_uri     | varchar(255)     | YES  |     | NULL                |                               |\n| sandbox_api_key          | char(36)         | YES  |     | NULL                |                               |\n| production_client_id     | char(36)         | YES  |     | NULL                |                               |\n| production_client_secret | varchar(255)     | YES  |     | NULL                |                               |\n| production_redirect_uri  | varchar(255)     | YES  |     | NULL                |                               |\n| production_api_key       | char(36)         | YES  |     | NULL                |                               |\n| created_at               | timestamp        | YES  |     | current_timestamp() |                               |\n| updated_at               | timestamp        | YES  |     | current_timestamp() | on update current_timestamp() |\n+--------------------------+------------------+------+-----+---------------------+-------------------------------+\n\u003c/pre\u003e\n\n### Table `token`\n\n\u003cpre\u003e\n+----------------+------------------------------+------+-----+---------------------+-------------------------------+\n| Field          | Type                         | Null | Key | Default             | Extra                         |\n+----------------+------------------------------+------+-----+---------------------+-------------------------------+\n| id             | int(11) unsigned             | NO   | PRI | NULL                | auto_increment                |\n| application_id | int(11)                      | NO   |     | NULL                |                               |\n| environment    | enum('sandbox','production') | YES  |     | NULL                |                               |\n| access_token   | varchar(550)                 | YES  |     | NULL                |                               |\n| refresh_token  | varchar(550)                 | YES  |     | NULL                |                               |\n| expires_in     | int(11)                      | YES  |     | NULL                |                               |\n| scope          | varchar(255)                 | YES  |     | NULL                |                               |\n| created_at     | timestamp                    | YES  |     | current_timestamp() |                               |\n| updated_at     | timestamp                    | YES  |     | current_timestamp() | on update current_timestamp() |\n| uuid           | char(36)                     | YES  |     | NULL                |                               |\n+----------------+------------------------------+------+-----+---------------------+-------------------------------+\n\u003c/pre\u003e\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspoje-net%2Fcsas-authorize","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspoje-net%2Fcsas-authorize","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspoje-net%2Fcsas-authorize/lists"}