{"id":19218712,"url":"https://github.com/fadilxcoder/reactjs-php","last_synced_at":"2025-02-23T09:14:47.656Z","repository":{"id":178030151,"uuid":"655086745","full_name":"fadilxcoder/reactjs-php","owner":"fadilxcoder","description":"PHP API (Single file Api with CRUD \"user\" endpoint) / ReactJS","archived":false,"fork":false,"pushed_at":"2023-07-10T19:37:34.000Z","size":325,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-04T19:23:29.625Z","etag":null,"topics":["api","api-server","crud","mysql","newman","php","poc","react","reactjs","sqlite"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fadilxcoder.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2023-06-17T21:03:38.000Z","updated_at":"2023-06-25T19:03:56.000Z","dependencies_parsed_at":null,"dependency_job_id":"fd33ae11-ed6b-49a6-a90c-fa1b2a0cd58f","html_url":"https://github.com/fadilxcoder/reactjs-php","commit_stats":null,"previous_names":["fadilxcoder/reactjs-php"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fadilxcoder%2Freactjs-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fadilxcoder%2Freactjs-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fadilxcoder%2Freactjs-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fadilxcoder%2Freactjs-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fadilxcoder","download_url":"https://codeload.github.com/fadilxcoder/reactjs-php/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240292395,"owners_count":19778311,"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","api-server","crud","mysql","newman","php","poc","react","reactjs","sqlite"],"created_at":"2024-11-09T14:27:50.555Z","updated_at":"2025-02-23T09:14:47.599Z","avatar_url":"https://github.com/fadilxcoder.png","language":"PHP","readme":"# Notes\n\nOne file API with CRUD / SQLite\n\n* Create database : `touch app.db` \n\n\n* BASE URL : `http://localhost/sqlite-api/`  \n\n* Virtual host : `http://users.php.sqlite.app.local/api`\n\n* HTTP response status codes : https://developer.mozilla.org/en-US/docs/Web/HTTP/Status\n\n\n* Database schema\n\n```sql\n\nDROP TABLE IF EXISTS `users`;\n\nCREATE TABLE IF NOT EXISTS `users` (\n    `id` INTEGER PRIMARY KEY AUTOINCREMENT,\n    `name` VARCHAR(50),\n    `email` VARCHAR(60),\n    `phone` BIGINT(10),\n    `token` VARCHAR(100),\n    `created_at` TIMESTAMP,\n    `updated_at` TIMESTAMP\n);\n```\n\n* RUN `newman run postman_collection.json`\n\n```bash\n\nOne File API\n\n→ users\n  GET http://localhost/sqlite-api/ [200 OK, 2kB, 460ms]\n\n→ users/:id\n  GET http://localhost/sqlite-api/index/1 [200 OK, 405B, 423ms]\n\n→ users\n  POST http://localhost/sqlite-api/ [200 OK, 603B, 455ms]\n\n→ users\n  PUT http://localhost/sqlite-api/ [200 OK, 433B, 435ms]\n\n→ users\n  DELETE http://localhost/sqlite-api/index/1 [200 OK, 430B, 420ms]\n\n┌─────────────────────────┬────────────────────┬────────────────────┐\n│                         │           executed │             failed │\n├─────────────────────────┼────────────────────┼────────────────────┤\n│              iterations │                  1 │                  0 │\n├─────────────────────────┼────────────────────┼────────────────────┤\n│                requests │                  5 │                  0 │\n├─────────────────────────┼────────────────────┼────────────────────┤\n│            test-scripts │                  0 │                  0 │\n├─────────────────────────┼────────────────────┼────────────────────┤\n│      prerequest-scripts │                  0 │                  0 │\n├─────────────────────────┼────────────────────┼────────────────────┤\n│              assertions │                  0 │                  0 │\n├─────────────────────────┴────────────────────┴────────────────────┤\n│ total run duration: 2.6s                                          │\n├───────────────────────────────────────────────────────────────────┤\n│ total data received: 2.08kB (approx)                              │\n├───────────────────────────────────────────────────────────────────┤\n│ average response time: 438ms [min: 420ms, max: 460ms, s.d.: 16ms] │\n└───────────────────────────────────────────────────────────────────┘\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffadilxcoder%2Freactjs-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffadilxcoder%2Freactjs-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffadilxcoder%2Freactjs-php/lists"}