{"id":16761612,"url":"https://github.com/astronati/php-wordpress-api-response-parser","last_synced_at":"2026-03-06T14:31:55.371Z","repository":{"id":48115724,"uuid":"131912405","full_name":"astronati/php-wordpress-api-response-parser","owner":"astronati","description":"Allows to map responses provided by any Wordpress API","archived":false,"fork":false,"pushed_at":"2022-10-30T10:51:57.000Z","size":72,"stargazers_count":5,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-24T15:41:50.832Z","etag":null,"topics":["php7","wordpress","wordpress-api","wordpress-php-library","wp"],"latest_commit_sha":null,"homepage":"https://astronati.github.io/php-wordpress-api-response-parser/","language":"PHP","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/astronati.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-05-02T22:28:37.000Z","updated_at":"2023-07-04T11:20:11.000Z","dependencies_parsed_at":"2022-08-12T19:00:19.662Z","dependency_job_id":null,"html_url":"https://github.com/astronati/php-wordpress-api-response-parser","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astronati%2Fphp-wordpress-api-response-parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astronati%2Fphp-wordpress-api-response-parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astronati%2Fphp-wordpress-api-response-parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astronati%2Fphp-wordpress-api-response-parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/astronati","download_url":"https://codeload.github.com/astronati/php-wordpress-api-response-parser/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248262434,"owners_count":21074308,"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":["php7","wordpress","wordpress-api","wordpress-php-library","wp"],"created_at":"2024-10-13T04:43:01.172Z","updated_at":"2025-04-10T17:52:12.976Z","avatar_url":"https://github.com/astronati.png","language":"PHP","readme":"[![Build Status](https://travis-ci.org/astronati/php-wordpress-api-response-parser.svg?branch=master)](https://travis-ci.org/astronati/php-sports-open-data-response-parser)\n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/b39ddb493f38495dbf0c7d59366ecd73)](https://www.codacy.com/app/astronati/php-wordpress-api-response-parser?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=astronati/php-wordpress-api-response-parser\u0026amp;utm_campaign=Badge_Grade)\n[![Codacy Badge](https://api.codacy.com/project/badge/Coverage/b39ddb493f38495dbf0c7d59366ecd73)](https://www.codacy.com/app/astronati/php-wordpress-api-response-parser?utm_source=github.com\u0026utm_medium=referral\u0026utm_content=astronati/php-wordpress-api-response-parser\u0026utm_campaign=Badge_Coverage)\n[![Latest Stable Version](https://poser.pugx.org/astronati/wordpress-api-response-parser/v/stable)](https://packagist.org/packages/astronati/wordpress-api-response-parser)\n[![License](https://poser.pugx.org/astronati/wordpress-api-response-parser/license)](https://packagist.org/packages/astronati/wordpress-api-response-parser)\n\n# Wordpress API Response Parser\nAllows to map responses provided by Wordpress API.\n\n## Supported Responses\nNot all responses are currently supported but we are happy to work for you if you need some of them.\n\n**NOTE:** To add another response into the supported list, please file a new issue.\n\nTo do that please file a new [issue](https://github.com/astronati/php-wordpress-api-response-parser/issues/new).\n\n## Installation\nYou can install the library and its dependencies using `composer` running:\n```sh\n$ composer require astronati/wordpress-api-response-parser\n```\n\n### Usage\nThe library allows to return a model per each response and its content (post, tag, category, etc...).\n\n##### Example\nThe following snippet can be helpful:\n\n```php\nuse WARP\\Response\\ResponseParser;\n...\n// Obtain a Response\n$apiResponse = ['id' =\u003e 123, ...] // Save the response from a Wordpress API\n$response = ResponseParser::create($apiResponse, ResponseParser::CREATE_POST);\n...\n// Get post\n$post = $response-\u003egetPost();\necho $post-\u003egetID(); // 123\n```\n\nFor more details please take a look at [Response](https://github.com/astronati/php-wordpress-api-response-parser/tree/master/src/Response).\n\n## Development\nThe environment requires [phpunit](https://phpunit.de/), that has been already included in the `dev-dependencies` of the\n`composer.json`.\n\n### Dependencies\nTo install all modules you just need to run following command:\n\n```sh\n$ composer install\n```\n\n### Testing\nTests files are created in dedicates folders that replicate the\n[src](https://github.com/astronati/php-wordpress-api-response-parser/tree/master/src) structure as follows:\n```\n.\n+-- src\n|   +-- [folder-name]\n|   |   +-- [file-name].php\n|   ...\n+-- tests\n|   +-- [folder-name]\n|   |   +-- [file-name]Test.php\n```\n\nExecute following command to run the tests suite:\n```sh\n$ composer test\n```\n\nRun what follows to see the code coverage:\n```sh\n$ composer coverage\n```\n\n## License\nThis package is released under the [MIT license](LICENSE.md).\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fastronati%2Fphp-wordpress-api-response-parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fastronati%2Fphp-wordpress-api-response-parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fastronati%2Fphp-wordpress-api-response-parser/lists"}