Activities

  • Return all of the project's activities

    GET /api/1/projects/:project_uuid/activities.json
    Formats
    json jsonp

    Returns an array of activity objects belonging to the project with the supplied project_uuid. Can take a URL-encoded, SQL-like query string and order string which can help filter and order the results that will be returned. So the query string:

    name ~= "quia+itaque"

    which lookes like this when URL encoded:

    /api/1/projects/ac995fed-1d62-438b-8559-c2a1b0d9126e/activities.json?where=name~%3D"quia+itaque"&order=name+asc

    will return all activities for the given project that are similar to “quia itaque” ordered by name in ascending order.

    Click here for more information on the API query string.

    Errors
    • 401 Unauthorized
    Example
    GET /api/1/projects/5091ff4f-d89e-46de-bf4a-7f68daff911d/activities
    200
    {
      "response": [
        {
          "name": "voluptas dolores",
          "project_uuid": "5091ff4f-d89e-46de-bf4a-7f68daff911d",
          "uuid": "274e9cdb-9770-4e79-8b79-0231ba90799b"
        },
        {
          "name": "blanditiis corporis",
          "project_uuid": "5091ff4f-d89e-46de-bf4a-7f68daff911d",
          "uuid": "dde9213a-4ca7-4213-aba4-10191482cbcc"
        },
        {
          "name": "et et",
          "project_uuid": "5091ff4f-d89e-46de-bf4a-7f68daff911d",
          "uuid": "eb839447-d27b-446b-af92-42b3da8e10a6"
        }
      ],
      "count": 3
    }
    Parameters
    • where

      An URL encoded, SQL-like query string which can filter the results that will be returned

    • order

      An URL encoded SQL-like order string, that sets the order of the returned objects

  • Return a single activity that belongs to the project

    GET /api/1/projects/:project_uuid/activities/:uuid.json
    Formats
    json jsonp

    Returns a single activity object belonging to the project with the supplied project_uuid

    Errors
    • 401 Unauthorized
    • 404 Record Not Found - returned if a project with the specified UUID is not found
    • 404 Record Not Found - returned if an activity with the specified UUID is not found
    Example
    GET /api/1/projects/99cef4da-c4b4-4b1b-a301-43ddc21ca91e/activities/a431a8e4-8b84-40b6-ae00-4613577e8b26
    200
    {
      "response": {
        "name": "delectus qui",
        "project_uuid": "99cef4da-c4b4-4b1b-a301-43ddc21ca91e",
        "uuid": "a431a8e4-8b84-40b6-ae00-4613577e8b26"
      }
    }
  • Create a new activity

    POST /api/1/projects/:project_uuid/activities.json
    Formats
    json jsonp

    Creates a new activity. Requires a valid activity object to be posted.

    Errors
    • 401 Unauthorized
    • 422 Invalid Record - if the activity fails validation. An error message will be returned, declaring the error.
    Example
    POST /api/1/projects/17940303-c9f5-4845-9eee-f4b29235e875/activities
    {
      "activity": {
        "name": "vero aut"
      }
    }
    200
    {
      "response": {
        "name": "vero aut",
        "project_uuid": "17940303-c9f5-4845-9eee-f4b29235e875",
        "uuid": "a25e5a89-2742-41c8-b15b-d4a406d235d0"
      }
    }
    Parameters
    • activity

      An activity JSON object.

      • uuid

        A UUID to identify the activity. If omitted, one will be generated

      • name

        Label of the activity

      • project_uuid

        UUID of the project the actvitity belongs to

  • Update an activity

    PUT /api/1/projects/:project_uuid/activities/:uuid.json
    Formats
    json jsonp

    Update an existing activity. Requires a valid activity object to be posted. Missing attributes from the object will be merged with the existing activity.

    Errors
    • 401 Unauthorized
    • 404 Record Not Found - returned if a project with the specified UUID is not found
    • 404 Record Not Found - returned if an activity with the specified UUID is not found
    • 422 Invalid Record - if the activity fails validation. An error message will be returned, declaring the error.
    Example
    PUT /api/1/projects/9e5872e3-6d76-4e06-86f2-5471c45359fd/activities/6eedf277-0733-4000-898e-68ca408df145
    {
      "activity": {
        "name": "sint ad"
      }
    }
    200
    Parameters
    • activity

      An activity JSON object.

      • uuid

        A UUID to identify the activity. If omitted, one will be generated

      • name

        Label of the activity

      • project_uuid

        UUID of the project the actvitity belongs to

  • Delete an activity

    DELETE /api/1/projects/:project_uuid/activities/:uuid.json
    Formats
    json jsonp

    Deletes the activity associated with the supplied uuid.

    Errors
    • 401 Unauthorized
    • 404 Record Not Found - returned if a project with the specified UUID is not found
    • 404 Record Not Found - returned if an activity with the specified UUID is not found
    Example
    DELETE /api/1/projects/905a9bde-b287-4a15-a863-813dc1d30ae4/activities/72779fdc-7de8-49bc-b74c-7725e8274e98
    200