Here we will give you the information you need to work with errors in the FRAPI CLI. Below are a list of valid arguments along with the options they accept and an example of each.
Add a new error to the system.
Example: $ ./frapi.php add error --name=ERROR1 --code=412 --message="There was an error processing your request." --description="This is a test error."
Option | Required | Description |
---|---|---|
--name|-n | Yes | The name of the error being created. |
--code|-c | No | The http code of the error being created. |
--message|-m | Yes | The meesage of the error being created. |
--description|-d | No | Description of error being created, used for documentation. |
Delete an error from the system.
Example: $ ./frapi.php delete error --name="ERROR1"
Option | Required | Description | |
---|---|---|---|
--name|-n | Yes | Name of error to delete. |
List all the errors in the system and their details.
Example: $ ./frapi.php list errors