PHP code example of ysato / catalyst

1. Go to this page and download the library: Download ysato/catalyst library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ysato / catalyst example snippets

shell
php artisan catalyst:scaffold
shell
php artisan catalyst:scaffold <vendor> <package> <php>
shell
php artisan catalyst:scaffold MyVendor MyProject 8.3
shell
php artisan catalyst:scaffold MyCorp WebApp 8.3 --with-ca-file=./certs/certificate.pem
shell
php artisan ide-helper:generate
php artisan ide-helper:models -N
php artisan ide-helper:meta

+-------------+--------+-------------------------------------------+-------------+
| IMPLEMENTED | METHOD | ENDPOINT                                  | STATUS CODE |
+-------------+--------+-------------------------------------------+-------------+
| ✅          | GET    | /threads                                  | 200         |
| ✅          | POST   | /threads                                  | 201         |
| ✅          | POST   | /threads                                  | 422         |
| ✅          | POST   | /threads                                  | 401         |
| ✅          | GET    | /threads/{threadid}                       | 200         |
| ✅          | GET    | /threads/{threadid}                       | 404         |
| ❌          | PUT    | /threads/{threadid}                       | 204         |
| ❌          | PUT    | /threads/{threadid}                       | 401         |
| ❌          | PUT    | /threads/{threadid}                       | 403         |
| ❌          | PUT    | /threads/{threadid}                       | 404         |
| ❌          | PUT    | /threads/{threadid}                       | 422         |
| ❌          | DELETE | /threads/{threadid}                       | 204         |
| ❌          | DELETE | /threads/{threadid}                       | 401         |
| ❌          | DELETE | /threads/{threadid}                       | 403         |
| ❌          | DELETE | /threads/{threadid}                       | 404         |
| ❌          | POST   | /threads/{threadid}/scratches             | 201         |
| ❌          | POST   | /threads/{threadid}/scratches             | 401         |
| ❌          | POST   | /threads/{threadid}/scratches             | 403         |
| ❌          | POST   | /threads/{threadid}/scratches             | 404         |
| ❌          | POST   | /threads/{threadid}/scratches             | 422         |
| ❌          | PUT    | /threads/{threadid}/scratches/{scratchid} | 204         |
| ❌          | PUT    | /threads/{threadid}/scratches/{scratchid} | 401         |
| ❌          | PUT    | /threads/{threadid}/scratches/{scratchid} | 403         |
| ❌          | PUT    | /threads/{threadid}/scratches/{scratchid} | 404         |
| ❌          | PUT    | /threads/{threadid}/scratches/{scratchid} | 422         |
| ❌          | DELETE | /threads/{threadid}/scratches/{scratchid} | 204         |
| ❌          | DELETE | /threads/{threadid}/scratches/{scratchid} | 401         |
| ❌          | DELETE | /threads/{threadid}/scratches/{scratchid} | 403         |
| ❌          | DELETE | /threads/{threadid}/scratches/{scratchid} | 404         |
+-------------+--------+-------------------------------------------+-------------+