GET api/Village/{village}/Tasks

Get tasks matching specified criteria

Request Information

URI Parameters

NameDescriptionTypeAdditional information
village

Village ID

globally unique identifier

Required

Completed

If true, returns tasks which have been completed. If false, returns tasks which have not been completed. If not set, returns all tasks regardless of completion status.

boolean

None.

AssignedToUserId

If set, retrieves activities assigned to the specified user. If not set, returns activities regardless of user assignment. To retrieve unassigned activities, pass the special value Guid.Empty (00000000-0000-0000-0000-000000000000).

globally unique identifier

None.

WithHistory

If true, the activity history (comments, assignments, etc.) will be included for all activities in the result; defaults to false

boolean

None.

SearchText

If provided, include only activities which contain the specified SearchText in a text field

string

None.

Tags

If provided, include only activities containing one or more of the specified tags

Collection of string

None.

LastUpdated

If set, returns events updated >= value

date

None.

Body Parameters

None.

Response Information

Resource Description

Collection of ViewTaskModel
NameDescriptionTypeAdditional information
Location

Obsolete

string

None.

DueDate

Obsolete

date

None.

Description

Obsolete

string

None.

Priority

Obsolete

boolean

None.

Reminder

If specified, the date and time by which the task is due

date

None.

TimeZone

Reminder time zone

string

None.

Completed

If set, the Date/Time at which the task was marked as completed

date

None.

CompletedById

For completed tasks, the ID of the user who completed the task

globally unique identifier

None.

CompletedBy

For completed tasks, the name of the user who completed the task

string

None.

ActivityId

Activity's unique ID

globally unique identifier

None.

CreatedById

ID of the user who created the activity

globally unique identifier

None.

CreatedBy

Name of the user who created the activity

string

None.

Created

Date/Time when the activity was created

date

None.

AssignedTo

List of users the activity is assigned to

Collection of ActivityAssignmentModel

None.

Tags

List of tags for the activity

Collection of string

None.

Attachments

File attachments

Collection of AttachmentModel

None.

History

Activity activity history

Collection of ActivityHistoryModel

None.

CommentCount

Number of entries in History which are comments

integer

None.

VillageId

The ID of the village in which this activity belongs

globally unique identifier

None.

LastUpdated

The date/time this activity was last updated; useful for handling push notifications

date

None.

Cancelled

True for activities that have been cancelled. Default value is false

boolean

None.

Title

Short title for the activity

string

Required

String length: inclusive between 0 and 255

Response Formats

application/json, text/json

Sample:
[
  {
    "Location": "sample string 1",
    "DueDate": "2025-06-03T04:43:51.086+00:00",
    "Description": "sample string 2",
    "Priority": true,
    "Reminder": "2025-06-03T04:43:51.086+00:00",
    "TimeZone": "sample string 4",
    "Completed": "2025-06-03T04:43:51.086+00:00",
    "CompletedById": "d70e2154-aba4-4c3e-a059-69e047ef48cf",
    "CompletedBy": "sample string 5",
    "ActivityId": "ee3eefb2-b9aa-482d-9ae4-c67fd29acfcc",
    "CreatedById": "8810bf11-b822-45ee-a3dc-36cc004f493b",
    "CreatedBy": "sample string 8",
    "Created": "2025-06-03T04:43:51.086+00:00",
    "AssignedTo": [
      {
        "UserId": "6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e",
        "Name": "sample string 2"
      },
      {
        "UserId": "6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e",
        "Name": "sample string 2"
      }
    ],
    "Tags": [
      "sample string 1",
      "sample string 2"
    ],
    "Attachments": [
      {
        "Id": "0376d27f-a001-492e-b4d1-546807fe4121",
        "Size": 2,
        "FileName": "sample string 3",
        "ContentType": "sample string 4",
        "UploadedBy": "sample string 5"
      },
      {
        "Id": "0376d27f-a001-492e-b4d1-546807fe4121",
        "Size": 2,
        "FileName": "sample string 3",
        "ContentType": "sample string 4",
        "UploadedBy": "sample string 5"
      }
    ],
    "History": [
      {
        "HistoryId": "46f7f6ec-3517-4dae-9745-1e32a930b214",
        "ActivityId": "0ecf67a5-9332-48f1-8d3c-e7735999313c",
        "PerformedById": "81186331-8896-4eca-9587-f171c31c3233",
        "PerformedBy": "sample string 4",
        "AssignedToId": "de113f48-b57f-48af-bde2-ea077e322fc3",
        "AssignedTo": "sample string 5",
        "Action": "Comment",
        "DateTime": "2025-06-03T04:43:51.086+00:00",
        "Comments": "sample string 7",
        "Updated": "2025-06-03T04:43:51.086+00:00",
        "UpdatedById": "828cd03d-1172-4ff2-b88b-f4c0cc815a32",
        "UpdatedBy": "sample string 10"
      },
      {
        "HistoryId": "46f7f6ec-3517-4dae-9745-1e32a930b214",
        "ActivityId": "0ecf67a5-9332-48f1-8d3c-e7735999313c",
        "PerformedById": "81186331-8896-4eca-9587-f171c31c3233",
        "PerformedBy": "sample string 4",
        "AssignedToId": "de113f48-b57f-48af-bde2-ea077e322fc3",
        "AssignedTo": "sample string 5",
        "Action": "Comment",
        "DateTime": "2025-06-03T04:43:51.086+00:00",
        "Comments": "sample string 7",
        "Updated": "2025-06-03T04:43:51.086+00:00",
        "UpdatedById": "828cd03d-1172-4ff2-b88b-f4c0cc815a32",
        "UpdatedBy": "sample string 10"
      }
    ],
    "CommentCount": 2,
    "VillageId": "09fb9a0a-1668-4bc0-825e-890068d87343",
    "LastUpdated": "2025-06-03T04:43:51.086+00:00",
    "Cancelled": true,
    "Title": "sample string 13"
  },
  {
    "Location": "sample string 1",
    "DueDate": "2025-06-03T04:43:51.086+00:00",
    "Description": "sample string 2",
    "Priority": true,
    "Reminder": "2025-06-03T04:43:51.086+00:00",
    "TimeZone": "sample string 4",
    "Completed": "2025-06-03T04:43:51.086+00:00",
    "CompletedById": "d70e2154-aba4-4c3e-a059-69e047ef48cf",
    "CompletedBy": "sample string 5",
    "ActivityId": "ee3eefb2-b9aa-482d-9ae4-c67fd29acfcc",
    "CreatedById": "8810bf11-b822-45ee-a3dc-36cc004f493b",
    "CreatedBy": "sample string 8",
    "Created": "2025-06-03T04:43:51.086+00:00",
    "AssignedTo": [
      {
        "UserId": "6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e",
        "Name": "sample string 2"
      },
      {
        "UserId": "6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e",
        "Name": "sample string 2"
      }
    ],
    "Tags": [
      "sample string 1",
      "sample string 2"
    ],
    "Attachments": [
      {
        "Id": "0376d27f-a001-492e-b4d1-546807fe4121",
        "Size": 2,
        "FileName": "sample string 3",
        "ContentType": "sample string 4",
        "UploadedBy": "sample string 5"
      },
      {
        "Id": "0376d27f-a001-492e-b4d1-546807fe4121",
        "Size": 2,
        "FileName": "sample string 3",
        "ContentType": "sample string 4",
        "UploadedBy": "sample string 5"
      }
    ],
    "History": [
      {
        "HistoryId": "46f7f6ec-3517-4dae-9745-1e32a930b214",
        "ActivityId": "0ecf67a5-9332-48f1-8d3c-e7735999313c",
        "PerformedById": "81186331-8896-4eca-9587-f171c31c3233",
        "PerformedBy": "sample string 4",
        "AssignedToId": "de113f48-b57f-48af-bde2-ea077e322fc3",
        "AssignedTo": "sample string 5",
        "Action": "Comment",
        "DateTime": "2025-06-03T04:43:51.086+00:00",
        "Comments": "sample string 7",
        "Updated": "2025-06-03T04:43:51.086+00:00",
        "UpdatedById": "828cd03d-1172-4ff2-b88b-f4c0cc815a32",
        "UpdatedBy": "sample string 10"
      },
      {
        "HistoryId": "46f7f6ec-3517-4dae-9745-1e32a930b214",
        "ActivityId": "0ecf67a5-9332-48f1-8d3c-e7735999313c",
        "PerformedById": "81186331-8896-4eca-9587-f171c31c3233",
        "PerformedBy": "sample string 4",
        "AssignedToId": "de113f48-b57f-48af-bde2-ea077e322fc3",
        "AssignedTo": "sample string 5",
        "Action": "Comment",
        "DateTime": "2025-06-03T04:43:51.086+00:00",
        "Comments": "sample string 7",
        "Updated": "2025-06-03T04:43:51.086+00:00",
        "UpdatedById": "828cd03d-1172-4ff2-b88b-f4c0cc815a32",
        "UpdatedBy": "sample string 10"
      }
    ],
    "CommentCount": 2,
    "VillageId": "09fb9a0a-1668-4bc0-825e-890068d87343",
    "LastUpdated": "2025-06-03T04:43:51.086+00:00",
    "Cancelled": true,
    "Title": "sample string 13"
  }
]

application/xml, text/xml

Sample:
<ArrayOfViewTaskModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CaringVillage.Shared.Implementation.Models">
  <ViewTaskModel>
    <Title>sample string 13</Title>
    <ActivityId>ee3eefb2-b9aa-482d-9ae4-c67fd29acfcc</ActivityId>
    <AssignedTo>
      <ActivityAssignmentModel>
        <Name>sample string 2</Name>
        <UserId>6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e</UserId>
      </ActivityAssignmentModel>
      <ActivityAssignmentModel>
        <Name>sample string 2</Name>
        <UserId>6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e</UserId>
      </ActivityAssignmentModel>
    </AssignedTo>
    <Attachments>
      <AttachmentModel>
        <ContentType>sample string 4</ContentType>
        <FileName>sample string 3</FileName>
        <Id>0376d27f-a001-492e-b4d1-546807fe4121</Id>
        <Size>2</Size>
        <UploadedBy>sample string 5</UploadedBy>
      </AttachmentModel>
      <AttachmentModel>
        <ContentType>sample string 4</ContentType>
        <FileName>sample string 3</FileName>
        <Id>0376d27f-a001-492e-b4d1-546807fe4121</Id>
        <Size>2</Size>
        <UploadedBy>sample string 5</UploadedBy>
      </AttachmentModel>
    </Attachments>
    <Cancelled>true</Cancelled>
    <Created>2025-06-03T04:43:51.0862929+00:00</Created>
    <CreatedBy>sample string 8</CreatedBy>
    <CreatedById>8810bf11-b822-45ee-a3dc-36cc004f493b</CreatedById>
    <History>
      <ActivityHistoryModel>
        <ActivityId>0ecf67a5-9332-48f1-8d3c-e7735999313c</ActivityId>
        <AssignedTo>sample string 5</AssignedTo>
        <AssignedToId>de113f48-b57f-48af-bde2-ea077e322fc3</AssignedToId>
        <Comments>sample string 7</Comments>
        <DateTime>2025-06-03T04:43:51.0862929+00:00</DateTime>
        <HistoryId>46f7f6ec-3517-4dae-9745-1e32a930b214</HistoryId>
        <PerformedBy>sample string 4</PerformedBy>
        <PerformedById>81186331-8896-4eca-9587-f171c31c3233</PerformedById>
        <Updated>2025-06-03T04:43:51.0862929+00:00</Updated>
        <UpdatedBy>sample string 10</UpdatedBy>
        <UpdatedById>828cd03d-1172-4ff2-b88b-f4c0cc815a32</UpdatedById>
      </ActivityHistoryModel>
      <ActivityHistoryModel>
        <ActivityId>0ecf67a5-9332-48f1-8d3c-e7735999313c</ActivityId>
        <AssignedTo>sample string 5</AssignedTo>
        <AssignedToId>de113f48-b57f-48af-bde2-ea077e322fc3</AssignedToId>
        <Comments>sample string 7</Comments>
        <DateTime>2025-06-03T04:43:51.0862929+00:00</DateTime>
        <HistoryId>46f7f6ec-3517-4dae-9745-1e32a930b214</HistoryId>
        <PerformedBy>sample string 4</PerformedBy>
        <PerformedById>81186331-8896-4eca-9587-f171c31c3233</PerformedById>
        <Updated>2025-06-03T04:43:51.0862929+00:00</Updated>
        <UpdatedBy>sample string 10</UpdatedBy>
        <UpdatedById>828cd03d-1172-4ff2-b88b-f4c0cc815a32</UpdatedById>
      </ActivityHistoryModel>
    </History>
    <LastUpdated>2025-06-03T04:43:51.0862929+00:00</LastUpdated>
    <Tags xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>sample string 1</d3p1:string>
      <d3p1:string>sample string 2</d3p1:string>
    </Tags>
    <VillageId>09fb9a0a-1668-4bc0-825e-890068d87343</VillageId>
    <Completed>2025-06-03T04:43:51.0862929+00:00</Completed>
    <CompletedBy>sample string 5</CompletedBy>
    <CompletedById>d70e2154-aba4-4c3e-a059-69e047ef48cf</CompletedById>
    <Description>sample string 2</Description>
    <DueDate>2025-06-03T04:43:51.0862929+00:00</DueDate>
    <Location>sample string 1</Location>
    <Priority>true</Priority>
    <Reminder>2025-06-03T04:43:51.0862929+00:00</Reminder>
    <TimeZone>sample string 4</TimeZone>
  </ViewTaskModel>
  <ViewTaskModel>
    <Title>sample string 13</Title>
    <ActivityId>ee3eefb2-b9aa-482d-9ae4-c67fd29acfcc</ActivityId>
    <AssignedTo>
      <ActivityAssignmentModel>
        <Name>sample string 2</Name>
        <UserId>6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e</UserId>
      </ActivityAssignmentModel>
      <ActivityAssignmentModel>
        <Name>sample string 2</Name>
        <UserId>6175dcd4-fcf4-48ad-be9a-4c3b288cfa2e</UserId>
      </ActivityAssignmentModel>
    </AssignedTo>
    <Attachments>
      <AttachmentModel>
        <ContentType>sample string 4</ContentType>
        <FileName>sample string 3</FileName>
        <Id>0376d27f-a001-492e-b4d1-546807fe4121</Id>
        <Size>2</Size>
        <UploadedBy>sample string 5</UploadedBy>
      </AttachmentModel>
      <AttachmentModel>
        <ContentType>sample string 4</ContentType>
        <FileName>sample string 3</FileName>
        <Id>0376d27f-a001-492e-b4d1-546807fe4121</Id>
        <Size>2</Size>
        <UploadedBy>sample string 5</UploadedBy>
      </AttachmentModel>
    </Attachments>
    <Cancelled>true</Cancelled>
    <Created>2025-06-03T04:43:51.0862929+00:00</Created>
    <CreatedBy>sample string 8</CreatedBy>
    <CreatedById>8810bf11-b822-45ee-a3dc-36cc004f493b</CreatedById>
    <History>
      <ActivityHistoryModel>
        <ActivityId>0ecf67a5-9332-48f1-8d3c-e7735999313c</ActivityId>
        <AssignedTo>sample string 5</AssignedTo>
        <AssignedToId>de113f48-b57f-48af-bde2-ea077e322fc3</AssignedToId>
        <Comments>sample string 7</Comments>
        <DateTime>2025-06-03T04:43:51.0862929+00:00</DateTime>
        <HistoryId>46f7f6ec-3517-4dae-9745-1e32a930b214</HistoryId>
        <PerformedBy>sample string 4</PerformedBy>
        <PerformedById>81186331-8896-4eca-9587-f171c31c3233</PerformedById>
        <Updated>2025-06-03T04:43:51.0862929+00:00</Updated>
        <UpdatedBy>sample string 10</UpdatedBy>
        <UpdatedById>828cd03d-1172-4ff2-b88b-f4c0cc815a32</UpdatedById>
      </ActivityHistoryModel>
      <ActivityHistoryModel>
        <ActivityId>0ecf67a5-9332-48f1-8d3c-e7735999313c</ActivityId>
        <AssignedTo>sample string 5</AssignedTo>
        <AssignedToId>de113f48-b57f-48af-bde2-ea077e322fc3</AssignedToId>
        <Comments>sample string 7</Comments>
        <DateTime>2025-06-03T04:43:51.0862929+00:00</DateTime>
        <HistoryId>46f7f6ec-3517-4dae-9745-1e32a930b214</HistoryId>
        <PerformedBy>sample string 4</PerformedBy>
        <PerformedById>81186331-8896-4eca-9587-f171c31c3233</PerformedById>
        <Updated>2025-06-03T04:43:51.0862929+00:00</Updated>
        <UpdatedBy>sample string 10</UpdatedBy>
        <UpdatedById>828cd03d-1172-4ff2-b88b-f4c0cc815a32</UpdatedById>
      </ActivityHistoryModel>
    </History>
    <LastUpdated>2025-06-03T04:43:51.0862929+00:00</LastUpdated>
    <Tags xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>sample string 1</d3p1:string>
      <d3p1:string>sample string 2</d3p1:string>
    </Tags>
    <VillageId>09fb9a0a-1668-4bc0-825e-890068d87343</VillageId>
    <Completed>2025-06-03T04:43:51.0862929+00:00</Completed>
    <CompletedBy>sample string 5</CompletedBy>
    <CompletedById>d70e2154-aba4-4c3e-a059-69e047ef48cf</CompletedById>
    <Description>sample string 2</Description>
    <DueDate>2025-06-03T04:43:51.0862929+00:00</DueDate>
    <Location>sample string 1</Location>
    <Priority>true</Priority>
    <Reminder>2025-06-03T04:43:51.0862929+00:00</Reminder>
    <TimeZone>sample string 4</TimeZone>
  </ViewTaskModel>
</ArrayOfViewTaskModel>