{"id":20806486,"url":"https://github.com/elipzis/aping","last_synced_at":"2026-04-29T05:05:56.077Z","repository":{"id":191743686,"uuid":"281031032","full_name":"elipZis/aPing","owner":"elipZis","description":"📲 A simple API Ping tool to feed a Swagger/OpenAPI 3.0 document file, call all paths and record time and responses","archived":false,"fork":false,"pushed_at":"2023-02-25T06:21:23.000Z","size":65,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-18T13:30:38.470Z","etag":null,"topics":["api","benchmark","golang","openapi","openapi3","ping","swagger"],"latest_commit_sha":null,"homepage":"","language":"Go","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/elipZis.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null},"funding":{"custom":["https://www.paypal.me/elipzis"]}},"created_at":"2020-07-20T06:17:44.000Z","updated_at":"2020-08-13T14:50:04.000Z","dependencies_parsed_at":"2023-08-31T13:08:45.030Z","dependency_job_id":null,"html_url":"https://github.com/elipZis/aPing","commit_stats":null,"previous_names":["elipzis/aping"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elipZis%2FaPing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elipZis%2FaPing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elipZis%2FaPing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elipZis%2FaPing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elipZis","download_url":"https://codeload.github.com/elipZis/aPing/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243152876,"owners_count":20244657,"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","benchmark","golang","openapi","openapi3","ping","swagger"],"created_at":"2024-11-17T19:20:20.266Z","updated_at":"2025-12-26T05:03:09.304Z","avatar_url":"https://github.com/elipZis.png","language":"Go","funding_links":["https://www.paypal.me/elipzis"],"categories":[],"sub_categories":[],"readme":"# aPing [![GitHub license](https://img.shields.io/github/license/elipzis/aPing.svg)](https://github.com/elipzis/aping/blob/master/LICENSE.md) [![GitHub (pre-)release](https://img.shields.io/badge/release-0.4.0-yellow.svg)](https://github.com/elipzis/aping/releases/tag/0.4.0) [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.me/elipzis)\nA simple API Ping tool to feed a Swagger/OpenAPI 3.0 document file, call all paths and record time and responses, e.g. to benchmark an endpoint.\n\n## Features\n* Read [Swagger/OpenAPI 3.0][2] api definition files and call all paths\n* Ping all paths in parallel workers and/or over several loops\n* Pass custom headers, e.g. `Authorization`\n* Create random `integer` and `string` parameters for urls\n* Track the time and response body per request\n* Output the results to console, CSV, HTML, JSON or Markdown\n\n## Latest Versions\n* 0.4.0\n  * Added regular expression filter option for paths\n  * Added response time milliseconds threshold\n* 0.3.0\n  * Added average ms calculation for multiple loops\n  * Added Bootstrap HTML template with sortable table\n  * Added JSON output\n* 0.2.0\n  * Added an option to configure included query methods\n  \nDownload the latest [release here][3].\n\n## Usage\nFor a quick start download a [release][3], change into the directory and execute the binary with your options, e.g.:\n```shell script\n./aping -input=\"calls.json\" -header='{\\\"Authorization\\\": \\\"Bearer eyXYZ\\\"}' -response -base=http://localhost:8080/api -out=html -l=5 -w=5\n```\n\nExample progress output:\n```\nPinging 'REST API Documentation - Backend'\nPinging 122 routes (Round 1) ... done! [122 in 11.586s]\nPinging 122 routes (Round 2) ... done! [122 in 23.315s]\nPinging 122 routes (Round 3) ... done! [122 in 37.262s]\nPinging 122 routes (Round 4) ... done! [122 in 48.616s]\nPinging 122 routes (Round 5) ... 27.9% ║█████████████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║ [34 in 1m1.386s]\n```\n\n### Options\n```shell script\nUsage\n  -input string\n        *The path/url to the Swagger/OpenAPI 3.0 input source\n  -base string\n        The base url to query\n  -header string\n        Pass a custom header as JSON string, e.g. '{\\\"Authorization\\\": \\\"Bearer TOKEN\\\"}' (default \"{}\")\n  -loop int\n        How often to loop through all calls (default 1)\n  -out string\n        The output format. Options: console, csv, html, md, json (default \"console\")\n  -response\n        Include the response body in the output\n  -timeout int\n        The timeout in seconds per request (default 5)\n  -worker int\n        The amount of parallel workers to use (default 1)\n  -methods string\n        An array of query methods to include, e.g. '[\\\"GET\\\", \\\"POST\\\"]' (default \"[\\\"GET\\\",\\\"POST\\\"]\")\n  -threshold int\n        Only collect pings above this response threshold in milliseconds (default -1)\n  -filter string\n        A regular expression to filter paths. Only matches will be pinged!\n```\n\n#### Input\nReference a file input somewhere reachable by your machine. \nReferences in the [OpenAPI][2] specification can be resolved if absolute or relative to the main file.\n\n#### Base\nPass a base url such as `http://localhost:8080/api`.\nIf non is given the `servers` array of the [OpenAPI][2] specification will be presented to pick a server from.\n\n#### Header\nPass custom headers to send with every request as an escaped JSON string such as `'{\\\"Authorization\\\": \\\"Bearer eyXYZ\\\"}'`.\n\nThe default headers are\n```\n\"Accept\":       \"*/*\"\n\"Connection\":   \"Keep-Alive\"\n\"Content-Type\": \"application/json\"\n\"User-Agent\":   \"aPing\"\n```\n\nYou can override these options by passing the same key.\n\n#### Worker\nHow many parallel processes should be spawned to query your endpoints.\n\n*Ensure that your endpoint can handle multiple requests, otherwise multiple workers might run into the timeout.*\n\n#### Output\nDefine an output format. The output is written to a local `aping.XYZ` file, depending on your choice.\n\nThe output contains (at most):\n* The pinged path\n* The effective URL*s* (base + path)\n* The query method\n* The average milliseconds\n* The response*s*\n\nSome data is only available with their according flags, i.e. `loop` and `response`\n\n#### Loop\n*If `loop \u003e 1` is mixed with `response` all responses are logged, if the path has parameters!*\n\n## Build\n[Download and install][5] Golang for your platform.\n\nClone this repository and build your own version:\n```shell script\ngit clone https://github.com/elipZis/aPing.git\ngo build -o aping github.com/elipZis/aPing\n```\n\n### Compatibility\naPing has been tested under the following conditions\n* Windows 10 Professional (64-bit)\n\n## Missing/Upcoming Features\naPing is not fully-fledged (yet). Some functionality is missing and errors may occur.\n\nKnown issues are:\n* Paths having request bodies are not pinged\n* Parameters besides `integer` and `string` are not pinged \n\n## License and Credits\naPing is released under the MIT license by [elipZis][1].\n\nThis program uses multiple other libraries. Credits and thanks to all the developers working on these great projects:\n* Swagger/OpenAPI 3.0 parser [kin-openapi][6]\n* Pretty console printer [go-pretty][7]\n\n## Disclaimer\nThis source and the whole package comes without a warranty. \nIt may or may not harm your computer. Please use with care. \nAny damage cannot be related back to the author. \nThe source has been tested on a virtual environment and scanned for viruses and has passed all tests.\n\n  [1]: https://elipZis.com\n  [2]: https://swagger.io/specification/\n  [3]: https://github.com/elipZis/aPing/releases\n  [4]: https://github.com/elipZis/aPing/wiki/Version-History\n  [5]: https://golang.org/dl/\n  [6]: https://github.com/getkin/kin-openapi\n  [7]: https://github.com/jedib0t/go-pretty\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felipzis%2Faping","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felipzis%2Faping","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felipzis%2Faping/lists"}