Skip to content

Projects

To create a new project you must include the following fields in your post:

  • name: String for the project name.
  • public_key: String for a public key. Could be an empty string if no key needed.
  • status: Boolean value that should be set to 0 or 1 used to set the project to active or inactive.

Creating a Project

POST route:

http://api.stevens-connect.com/project

Example for creating a project:

curl -H 'Authorization: bearer eyJ0eXAiOiJKV1Q...' -d "name=456test&public_key=123key&status=1" -X POST http://api.stevens-connect.com/project

POST response example:

{
  "errors": false,
  "data": {
    "project": {
      "public_key": "my_key",
      "name": "my_project_name",
      "status": 1,
      "company_id": 32,
      "id": 000
    }
  }
}

Updating a Project

All fields are optional for updates.

PATCH route:

http://api.stevens-connect.com/project/<project_id>

Example for updating a company's name where 'xxx' represents the project ID:

curl -H 'Authorization: bearer eyJ0eXAiOiJKV1Q...' -d "name=UpdatedCompanyName" -X PATCH http://api.stevens-connect.com/project/xxx

Deleting a Project

DELETE route:

http://api.stevens-connect.com/project/<project_id>

Example for deleting a project where 'xxx' represents the project ID:

curl -H 'Authorization: bearer eyJ0eXAiOiJKV1Q...' -X DELETE http://api.stevens-connect.com/project/xxx