{"id":28976174,"url":"https://github.com/oskratch/wordpress-plugin-jsonifywp","last_synced_at":"2026-03-16T15:02:42.326Z","repository":{"id":295284100,"uuid":"983092790","full_name":"oskratch/wordpress-plugin-jsonifywp","owner":"oskratch","description":"Manage and display remote JSON API data in WordPress. Create custom entries, apply templates, and embed external data anywhere on your site via shortcode.","archived":false,"fork":false,"pushed_at":"2025-06-19T21:54:09.000Z","size":59,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-19T22:33:40.692Z","etag":null,"topics":["json-api","plugin","wordpress"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/oskratch.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"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}},"created_at":"2025-05-13T21:38:22.000Z","updated_at":"2025-06-19T21:54:12.000Z","dependencies_parsed_at":"2025-05-24T17:34:07.059Z","dependency_job_id":"a853c6e5-f084-4591-b5bc-b15a16a96a99","html_url":"https://github.com/oskratch/wordpress-plugin-jsonifywp","commit_stats":null,"previous_names":["oskratch/wordpress-plugin-jsonifywp"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/oskratch/wordpress-plugin-jsonifywp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oskratch%2Fwordpress-plugin-jsonifywp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oskratch%2Fwordpress-plugin-jsonifywp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oskratch%2Fwordpress-plugin-jsonifywp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oskratch%2Fwordpress-plugin-jsonifywp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oskratch","download_url":"https://codeload.github.com/oskratch/wordpress-plugin-jsonifywp/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oskratch%2Fwordpress-plugin-jsonifywp/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263013703,"owners_count":23399812,"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":["json-api","plugin","wordpress"],"created_at":"2025-06-24T13:40:06.360Z","updated_at":"2026-03-16T15:02:42.319Z","avatar_url":"https://github.com/oskratch.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JsonifyWP\n\n![WordPress](https://img.shields.io/badge/WordPress-5.0%2B-blue.svg) ![PHP](https://img.shields.io/badge/PHP-7.4%2B-purple.svg) ![MySQL](https://img.shields.io/badge/MySQL-5.6%2B-orange.svg) ![License](https://img.shields.io/badge/License-GPL%20v2-green.svg)\n\nJsonifyWP is a WordPress plugin that lets you manage custom API endpoints—each with its own title, language, API URL (endpoint), templates, and detail page settings—stored in a dedicated database table. You can display data from remote JSON APIs on your site using flexible templates.\n\n## Features\n\n- **Admin interface** to manage endpoints with full configuration options\n- **Custom database table** (`wp_jsonifywp`) to store all endpoint configurations\n- **Multiple templates** for list and detail views (selectable per endpoint)\n- **Flexible shortcodes** to display API data using the selected template\n- **Template system** easily extensible with your own PHP templates\n- **Navigation support** between list and detail pages\n- **Smart URL handling** - shortcodes automatically read parameters from the URL\n- **Two operation modes**: full list-to-detail navigation or list-only with API pagination\n- **Endpoint duplication** for quick setup of similar configurations\n- **Multilingual support** with translation files in the `languages` folder\n\n## Installation\n\n1. Upload the `jsonifywp` folder to your WordPress `wp-content/plugins/` directory.\n2. Ensure the `templates/list/` and `templates/detail/` subfolders exist and contain at least one template each (e.g., `default.php` and `default_detail.php`).\n3. Activate the plugin from the WordPress admin panel.\n4. Go to the JsonifyWP menu in the admin sidebar to add and manage endpoints.\n\n## Configuration\n\n### Endpoint Fields\n\nWhen creating or editing an endpoint, you can configure:\n\n- **Title**: Display name for the endpoint\n- **Language**: For display purposes (language parameters should be included in the API URL if required)\n- **API domain**: Optional base domain to prepend to detail URLs if they are relative\n- **API URL**: Main list endpoint (do not include `page` or `limit` parameters, as these are handled automatically)\n- **List template**: Choose from available templates in `templates/list/`\n- **Detail template**: Choose from `templates/detail/` templates, or select **No detail page** for list-only mode\n- **Detail page URL**: Required only for detail mode - relative URL to the WordPress page containing `[jsonifywp_detail]`\n- **Detail API field**: Required only for detail mode - JSON field name containing the detail API URL\n\n### Operation Modes\n\n**Detail Mode (default):**\n- Each list item can link to a detail page showing expanded information\n- Requires a second API call to fetch detailed data\n- Suitable for member directories, product catalogs, etc.\n\n**List-only Mode:**\n- Select \"No detail page\" as the detail template\n- Displays only a paginated list with automatic API-driven pagination\n- The plugin automatically adds `page` and `limit` parameters to API requests\n- Ideal for publications, news feeds, or simple data lists\n\n### Global Settings\n\nConfigure global options from JsonifyWP \u003e Settings:\n\n- **Items per page**: Number of items to display per page for list-only endpoints\n\n### List-only API Response Format\n\nFor list-only endpoints, your API should return JSON in this format:\n\n```json\n{\n  \"total\": 42,\n  \"page\": 1,\n  \"limit\": 10,\n  \"items\": [\n    \"Information A...\",\n    \"Information B...\",\n    \"Information C...\",\n    \"...\"\n  ]\n}\n```\n\n- **total**: Total number of available items\n- **page**: Current page number\n- **limit**: Number of items per page\n- **items**: Array of items for the current page\n\n## Usage\n\n### Shortcodes\n\n**Display a List:**\n```\n[jsonifywp id=\"1\"]\n```\nOr use the alias format:\n```\n[jsonifywp-1]\n```\n\n**Display a Detail Page:**\n```\n[jsonifywp_detail]\n```\n\nYou can find the correct shortcode for each endpoint in the admin endpoints table, ready to copy and paste.\n\n### Setting up Detail Pages\n\n1. Create a WordPress page (e.g., `/detail/`) and add the `[jsonifywp_detail]` shortcode\n2. In JsonifyWP admin, set the **Detail page URL** field to match your page slug (e.g., `detail`)\n3. The plugin automatically handles URL parameters like `/detail/?jsonifywp_id=1\u0026item=2`\n\n### Navigation Flow\n\n- List templates use `$item_obj-\u003edetail_page_url` to generate correct detail page links\n- The plugin fetches the main API, extracts the detail URL from the configured JSON field\n- Makes a second API call to fetch and display detailed information\n\n## Templates\n\n### Creating Custom Templates\n\n- **List templates**: Place in `templates/list/` directory\n- **Detail templates**: Place in `templates/detail/` directory\n- Templates are standard PHP files with access to API data variables\n- Select templates per endpoint in the admin interface\n\n### Available Variables in Templates\n\n- `$json`: Decoded API response data\n- `$item_obj`: Full endpoint configuration object\n- `$type_id`: Current endpoint ID\n\n## Advanced Features\n\n### Duplicating Endpoints\n\nQuickly duplicate any endpoint from the admin endpoints list. Click the \"Duplicate\" action to create a new endpoint with the same configuration (title will have \"(copy)\" appended). This makes it easy to create similar endpoints without re-entering all details.\n\n### Accessing Configuration in Code\n\n**Get items per page setting:**\n```php\n$items_per_page = get_option('jsonifywp_items_per_page', 5);\n```\n\n**Access from JavaScript (if loaded):**\n```js\nconst itemsPerPage = window.jsonifywp_vars?.itemsPerPage || 5;\n```\n\n## License\n\nThis plugin is licensed under the GPLv2 or later. See [LICENSE](LICENSE) for details.\n\n---\n\n**Developed by Oscar Periche. Contributions welcome!**","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foskratch%2Fwordpress-plugin-jsonifywp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foskratch%2Fwordpress-plugin-jsonifywp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foskratch%2Fwordpress-plugin-jsonifywp/lists"}