{"id":24058279,"url":"https://github.com/genyleap/xcli","last_synced_at":"2026-02-09T23:33:38.284Z","repository":{"id":268787542,"uuid":"905471833","full_name":"genyleap/XCLI","owner":"genyleap","description":"XCLI is a command-line interface (CLI) tool for interacting with the Twitter API. It allows developers to perform actions such as authenticating via OAuth 2.0, retrieving information from API endpoints, and working with Twitter Spaces. This project is designed with a focus on simplicity, modularity, and extensibility.","archived":false,"fork":false,"pushed_at":"2024-12-20T05:29:44.000Z","size":83,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-05T05:02:00.498Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","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/genyleap.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":"CITATION.md","codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-18T22:36:05.000Z","updated_at":"2024-12-20T03:03:31.000Z","dependencies_parsed_at":"2024-12-18T23:26:53.927Z","dependency_job_id":"270c8c49-ddec-4138-8dda-bad6308bdc98","html_url":"https://github.com/genyleap/XCLI","commit_stats":null,"previous_names":["genyleap/xcli"],"tags_count":0,"template":false,"template_full_name":"genyleap/pt","purl":"pkg:github/genyleap/XCLI","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/genyleap%2FXCLI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/genyleap%2FXCLI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/genyleap%2FXCLI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/genyleap%2FXCLI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/genyleap","download_url":"https://codeload.github.com/genyleap/XCLI/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/genyleap%2FXCLI/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29285817,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-09T21:57:15.303Z","status":"ssl_error","status_checked_at":"2026-02-09T21:57:11.537Z","response_time":56,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2025-01-09T05:57:02.331Z","updated_at":"2026-02-09T23:33:38.271Z","avatar_url":"https://github.com/genyleap.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# XCLI\n\nXCLI is a command-line interface (CLI) tool for interacting with the Twitter API. It allows developers to perform actions such as authenticating via OAuth 2.0, retrieving information from API endpoints, and working with Twitter Spaces. This project is designed with a focus on simplicity, modularity, and extensibility.\n\n## Features\n\n- **OAuth 2.0 Authentication**: Securely authenticate with Twitter using bearer tokens.\n- **Custom API Requests**: Perform GET requests to specified Twitter API endpoints with query parameters.\n- **Twitter Spaces**: Fetch detailed information about Twitter Spaces by providing a Space ID.\n- **Extensive Logging**: Provides formatted error and info logs for better debugging and user feedback.\n\n## Requirements\n\n- **C++ Compiler**: A modern C++ compiler with support for C++20 or higher (e.g., GCC 10+, Clang 12+, or MSVC 2019+).\n- **Dependencies**:\n  - [cURL](https://curl.se/libcurl/) for HTTP requests.\n  - [JSON for Modern C++](https://github.com/open-source-parsers/jsoncpp) for parsing and generating JSON.\n- **Build Tools**:\n  - [CMake](https://cmake.org/) for building the project.\n\n## Installation\n\n### Clone the Repository\n\n```bash\ngit clone https://github.com/genyleap/XCLI.git\ncd XCLI\n```\n\n### Build the Project\n\n1. Create a build directory:\n   ```bash\n   mkdir build \u0026\u0026 cd build\n   ```\n\n2. Run CMake to configure the build:\n   ```bash\n   cmake ..\n   ```\n\n3. Build the project:\n   ```bash\n   cmake --build .\n   ```\n\n## Usage\n\n### Basic Command Structure\n\n```bash\nxcli \u003ccommand\u003e [options]\n```\n\n### Available Commands\n\n- **`auth`**: Authenticate with Twitter using OAuth 2.0.\n  ```bash\n  xcli auth\n  ```\n\n- **`get`**: Perform a GET request to a specified API endpoint.\n  ```bash\n  xcli get \u003cendpoint\u003e [key=value ...]\n  ```\n\n  Example:\n  ```bash\n  xcli get /2/users/by/username/johndoe user.fields=id,name,username\n  ```\n\n- **`space`**: Fetch information about a Twitter Space using its Space ID.\n  ```bash\n  xcli space \u003cspace_id\u003e\n  ```\n\n  Example:\n  ```bash\n  xcli space 1vOGwMNOZXYxB\n  ```\n\n### Example Output\n\n```plaintext\nAuthentication successful.\nTokens saved successfully to \"auth_tokens.json\".\n\nAPI Response:\n{\n    \"data\": {\n        \"id\": \"1vOGwMNOZXYxB\",\n        \"title\": \"Tech Talks\",\n        \"host_ids\": [\"123456789\"],\n        \"participant_count\": 150,\n        \"created_at\": \"2024-12-15T10:00:00Z\"\n    }\n}\n```\n\n## Project Structure\n\n```\nXCLI/\n├── source/               # Source code files \u0026 Header files\n│   └── xcli.hpp    # Declaration of XCLI class\n│   ├── xcli.cpp    # Main implementation of XCLI\n│   └── ...\n├── third-party/          # Third-party dependencies (e.g., JSON library)\n├── CMakeLists.txt        # CMake configuration\n└── README.md             # Project documentation\n```\n\n## Configuration\n\nModify the following constants in `xcli.hpp` as needed:\n\n- `tokenFile`: Path to the JSON file where authentication tokens are stored.\n\n## Contributing\n\nContributions are welcome! If you have ideas or improvements, feel free to submit a pull request or open an issue.\n\n### Steps to Contribute\n\n1. Fork the repository.\n2. Create a new branch:\n   ```bash\n   git checkout -b feature/your-feature\n   ```\n3. Commit your changes:\n   ```bash\n   git commit -m \"Add your feature description\"\n   ```\n4. Push to your fork:\n   ```bash\n   git push origin feature/your-feature\n   ```\n5. Submit a pull request.\n\n## License\n\nThis project is licensed under the [MIT License](LICENSE).\n\n## Acknowledgments\n\n- [Twitter API](https://developer.twitter.com/en/docs) for providing access to social data.\n- [cURL](https://curl.se/) for HTTP requests.\n- [JSON for Modern C++](https://github.com/open-source-parsers/jsoncpp) for JSON parsing.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgenyleap%2Fxcli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgenyleap%2Fxcli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgenyleap%2Fxcli/lists"}