{"id":13622441,"url":"https://github.com/rest-assured/rest-assured","last_synced_at":"2025-05-12T13:03:07.735Z","repository":{"id":1134108,"uuid":"1011539","full_name":"rest-assured/rest-assured","owner":"rest-assured","description":"Java DSL for easy testing of REST services","archived":false,"fork":false,"pushed_at":"2025-02-14T13:45:30.000Z","size":11312,"stargazers_count":6961,"open_issues_count":573,"forks_count":1891,"subscribers_count":324,"default_branch":"master","last_synced_at":"2025-05-05T07:38:53.934Z","etag":null,"topics":["groovy","http","java","json","kotlin","rest","rest-api","test","test-automation","xml"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rest-assured.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.txt","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","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,"zenodo":null},"funding":{"github":"johanhaleby"}},"created_at":"2010-10-21T08:35:43.000Z","updated_at":"2025-05-02T08:52:05.000Z","dependencies_parsed_at":"2023-07-05T15:46:33.063Z","dependency_job_id":"e10c456b-e860-4ca7-8208-aa8c6996afc9","html_url":"https://github.com/rest-assured/rest-assured","commit_stats":{"total_commits":2241,"total_committers":173,"mean_commits":"12.953757225433526","dds":"0.11780455153949132","last_synced_commit":"e1d96781fe67938078c906cda0a20665033a7c04"},"previous_names":["jayway/rest-assured"],"tags_count":81,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rest-assured%2Frest-assured","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rest-assured%2Frest-assured/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rest-assured%2Frest-assured/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rest-assured%2Frest-assured/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rest-assured","download_url":"https://codeload.github.com/rest-assured/rest-assured/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253745051,"owners_count":21957316,"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":["groovy","http","java","json","kotlin","rest","rest-api","test","test-automation","xml"],"created_at":"2024-08-01T21:01:19.256Z","updated_at":"2025-05-12T13:03:07.681Z","avatar_url":"https://github.com/rest-assured.png","language":"Java","funding_links":["https://github.com/sponsors/johanhaleby","https://www.buymeacoffee.com/johanhaleby"],"categories":["Java","API Testing","Projects","XML Tools and Frameworks","Testing","Test","[API Testing](TestingDomains.md/#api-testing)","HarmonyOS","自动化测试","Language-Specific API Testing Libraries","Uncategorized","测试","Awesome Tools","Tools","项目","Performance Testing"],"sub_categories":[".NET","Testing","In-memory data grids","Querying","Windows Manager","测试框架","70. [REST Assured](https://rest-assured.io/)","Uncategorized","Languages","Mesh networks","测试","API Testing","API Testing \u0026 Contract Testing"],"readme":"![REST Assured](rest-assured-logo-green.png)\n\n[![Build Status](https://github.com/rest-assured/rest-assured/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/rest-assured/rest-assured/actions/workflows/ci.yml)\n[![Maven Central](https://maven-badges.herokuapp.com/maven-central/io.rest-assured/rest-assured/badge.svg)](https://maven-badges.herokuapp.com/maven-central/io.rest-assured/rest-assured)\n\u003c!-- [![Javadoc](https://javadoc-badge.appspot.com/io.rest-assured/rest-assured.svg)](http://www.javadoc.io/doc/io.rest-assured/rest-assured) --\u003e\n\n\nTesting and validation of REST services in Java is harder than in dynamic languages \nsuch as Ruby and Groovy. REST Assured brings the simplicity of using these \nlanguages into the Java domain.\n\n\n## News\n* 2025-02-14: REST Assured 5.5.1 is released with bug fixes and minor improvements. See [change log](https://raw.githubusercontent.com/rest-assured/rest-assured/master/changelog.txt) for more details.\n* 2024-07-05: REST Assured 5.5.0 is released with several bug fixes and a new [Scala 3 Extension Module](https://github.com/rest-assured/rest-assured/wiki/Scala#scala-extension-module). See [change log](https://raw.githubusercontent.com/rest-assured/rest-assured/master/changelog.txt) for more details.\n* 2023-12-08: REST Assured 5.4.0 is released with several bug fixes and a [Kotlin Extension Module for Spring WebTest](https://github.com/rest-assured/rest-assured/wiki/Kotlin#kotlin-extension-module-for-spring-webtest). See [change log](https://raw.githubusercontent.com/rest-assured/rest-assured/master/changelog.txt) for more details.\n\n[Older News](https://github.com/rest-assured/rest-assured/wiki/OldNews)\n\n\n## Examples\nHere's an example of how to make a GET request and validate the JSON or XML response:\n\n```java\nget(\"/lotto\").then().assertThat().body(\"lotto.lottoId\", equalTo(5));\n```\n\nGet and verify all winner ids:\n\n```java\nget(\"/lotto\").then().assertThat().body(\"lotto.winners.winnerId\", hasItems(23, 54));\n```\n\nUsing parameters:\n\n```java\ngiven().\n    param(\"key1\", \"value1\").\n    param(\"key2\", \"value2\").\nwhen().\n    post(\"/somewhere\").\nthen().\n    body(containsString(\"OK\"));\n```\n\nUsing X-Path (XML only):\n\n```java\ngiven().\n    params(\"firstName\", \"John\", \"lastName\", \"Doe\").\nwhen().\n    post(\"/greetMe\").\nthen().\n    body(hasXPath(\"/greeting/firstName[text()='John']\")).\n```\n\nNeed authentication? REST Assured provides several authentication mechanisms:\n\n```java\ngiven().auth().basic(username, password).when().get(\"/secured\").then().statusCode(200);\n```\n\nGetting and parsing a response body:\n\n```java\n// Example with JsonPath\nString json = get(\"/lotto\").asString();\nList\u003cString\u003e winnerIds = from(json).get(\"lotto.winners.winnerId\");\n    \n// Example with XmlPath\nString xml = post(\"/shopping\").andReturn().body().asString();\nNode category = from(xml).get(\"shopping.category[0]\");\n```\n\nREST Assured supports any HTTP method but has explicit support for *POST*, *GET*, *PUT*, *DELETE*, *OPTIONS*, *PATCH* and *HEAD* and includes specifying and validating e.g. parameters, headers, cookies and body easily.\n\n\n## Documentation\n\n* [Getting started](https://github.com/rest-assured/rest-assured/wiki/GettingStarted)\n* [Usage Guide](https://github.com/rest-assured/rest-assured/wiki/Usage) (click [here](https://github.com/rest-assured/rest-assured/wiki/Usage_Legacy) for legacy documentation)\n* [Javadoc](http://www.javadoc.io/doc/io.rest-assured/rest-assured/5.5.1)\n* [Rest Assured Javadoc](http://static.javadoc.io/io.rest-assured/rest-assured/5.5.1/io/restassured/RestAssured.html)\n* [Rest AssuredMockMvc Javadoc](http://static.javadoc.io/io.rest-assured/spring-mock-mvc/5.5.1/io/restassured/module/mockmvc/RestAssuredMockMvc.html)\n* [XmlPath Javadoc](http://static.javadoc.io/io.rest-assured/xml-path/5.5.1/io/restassured/path/xml/XmlPath.html)\n* [JsonPath Javadoc](http://static.javadoc.io/io.rest-assured/json-path/5.5.1/io/restassured/path/json/JsonPath.html)\n* [Release Notes](https://github.com/rest-assured/rest-assured/wiki/ReleaseNotes)\n* [FAQ](https://github.com/rest-assured/rest-assured/wiki/FAQ)\n\n## Support and discussion\nJoin the mailing list at our [Google group](http://groups.google.com/group/rest-assured). \n\n## Links\n* [Change log](https://github.com/rest-assured/rest-assured/raw/master/changelog.txt)\n* REST Assured on [openhub](https://www.openhub.net/p/rest-assured)\n* [Mailing list](http://groups.google.com/group/rest-assured) for questions and support\n\n\u003ca href=\"https://www.buymeacoffee.com/johanhaleby\" target=\"_blank\"\u003e\u003cimg src=\"https://cdn.buymeacoffee.com/buttons/arial-blue.png\" alt=\"Buy Me A Coffee\" style=\"height: 42px !important;width: 180px !important;\" height=\"42px\" width=\"180px\"\u003e\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frest-assured%2Frest-assured","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frest-assured%2Frest-assured","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frest-assured%2Frest-assured/lists"}