POST api/delegates

Creates a new delegate.

Request Information

URI Parameters

None.

Body Parameters

The new delegate to create.

Delegate
NameDescriptionTypeAdditional information
Id

The delegate's id.

integer

None.

DelegateGroupId

The ID of the delegate group the delegate is in.

integer

None.

FirstName

The first name of the delegate.

string

None.

LastName

The last name of the delegate.

string

None.

Phone

The delegate's phone number.

string

None.

Username

The username that the delegate uses to log in to the system.

string

None.

Email

The delegate's email address.

string

None.

Role

The delegate's position relative to their organization or the passenger. For informational purposes.

string

None.

Comments

Gets or sets optional comments for the delegate.

string

None.

AddressComments

Gets or sets optional address comments for the delegate. This is helpful for situations where the delegate is a part of a Facility group but is working from a different branch or location.

string

None.

SecuritySettings

The security permissions for the delegate. If no security permissions have been defined for the delegate, this will fall back to the group security settings that the delegate inherits from

DelegateSecurity

None.

CanManageClients

Gets whether the delegate add/remove clients from the group

boolean

None.

CanManageDelegates

Gets whether the delegate can add/remove delegates from the group

boolean

None.

CanManageLocations

Gets whether the delegate can add/edit locations

boolean

None.

InheritGroupSecurity

Gets whether the delegate will have access to all settings the group does, in addition to its own security permissions

boolean

None.

DateCreated

Gets or sets the date on which delegate was created

date

None.

Request Formats

application/json, text/json

Sample:
{
  "id": 624,
  "delegateGroupId": 1,
  "firstName": "John",
  "lastName": "Doe",
  "phone": "555-555-5124",
  "username": "jdoe@example.com",
  "email": "jdoe@example.com",
  "role": "Care Worker",
  "comments": null,
  "addressComments": null,
  "securitySettings": {
    "canBookSubscriptions": false,
    "canBookTrips": true,
    "canEditProfile": false,
    "canViewProfile": true,
    "canCancelTrips": false,
    "canManagePassengerFeedback": false,
    "canEditCasualTrips": false,
    "canEditSubscriptionTrips": false
  },
  "canManageClients": false,
  "canManageDelegates": false,
  "canManageLocations": false,
  "inheritGroupSecurity": false,
  "dateCreated": null
}

application/xml, text/xml

Sample:
<Delegate xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TS.DR.Resources.Delegates">
  <AddressComments i:nil="true" />
  <CanManageClients>false</CanManageClients>
  <CanManageDelegates>false</CanManageDelegates>
  <CanManageLocations>false</CanManageLocations>
  <Comments i:nil="true" />
  <DateCreated i:nil="true" />
  <DelegateGroupId>1</DelegateGroupId>
  <Email>jdoe@example.com</Email>
  <FirstName>John</FirstName>
  <Id>624</Id>
  <InheritGroupSecurity>false</InheritGroupSecurity>
  <LastName>Doe</LastName>
  <Phone>555-555-5124</Phone>
  <Role>Care Worker</Role>
  <SecuritySettings>
    <CanBookSubscriptions>false</CanBookSubscriptions>
    <CanBookTrips>true</CanBookTrips>
    <CanCancelTrips>false</CanCancelTrips>
    <CanEditCasualTrips>false</CanEditCasualTrips>
    <CanEditProfile>false</CanEditProfile>
    <CanEditSubscriptionTrips>false</CanEditSubscriptionTrips>
    <CanManagePassengerFeedback>false</CanManagePassengerFeedback>
    <CanViewProfile>true</CanViewProfile>
  </SecuritySettings>
  <Username>jdoe@example.com</Username>
</Delegate>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

Returns the newly created delegate, including the ID generated for it.

Delegate
NameDescriptionTypeAdditional information
Id

The delegate's id.

integer

None.

DelegateGroupId

The ID of the delegate group the delegate is in.

integer

None.

FirstName

The first name of the delegate.

string

None.

LastName

The last name of the delegate.

string

None.

Phone

The delegate's phone number.

string

None.

Username

The username that the delegate uses to log in to the system.

string

None.

Email

The delegate's email address.

string

None.

Role

The delegate's position relative to their organization or the passenger. For informational purposes.

string

None.

Comments

Gets or sets optional comments for the delegate.

string

None.

AddressComments

Gets or sets optional address comments for the delegate. This is helpful for situations where the delegate is a part of a Facility group but is working from a different branch or location.

string

None.

SecuritySettings

The security permissions for the delegate. If no security permissions have been defined for the delegate, this will fall back to the group security settings that the delegate inherits from

DelegateSecurity

None.

CanManageClients

Gets whether the delegate add/remove clients from the group

boolean

None.

CanManageDelegates

Gets whether the delegate can add/remove delegates from the group

boolean

None.

CanManageLocations

Gets whether the delegate can add/edit locations

boolean

None.

InheritGroupSecurity

Gets whether the delegate will have access to all settings the group does, in addition to its own security permissions

boolean

None.

DateCreated

Gets or sets the date on which delegate was created

date

None.

Response Formats

application/json, text/json

Sample:
{
  "id": 624,
  "delegateGroupId": 1,
  "firstName": "John",
  "lastName": "Doe",
  "phone": "555-555-5124",
  "username": "jdoe@example.com",
  "email": "jdoe@example.com",
  "role": "Care Worker",
  "comments": null,
  "addressComments": null,
  "securitySettings": {
    "canBookSubscriptions": false,
    "canBookTrips": true,
    "canEditProfile": false,
    "canViewProfile": true,
    "canCancelTrips": false,
    "canManagePassengerFeedback": false,
    "canEditCasualTrips": false,
    "canEditSubscriptionTrips": false
  },
  "canManageClients": false,
  "canManageDelegates": false,
  "canManageLocations": false,
  "inheritGroupSecurity": false,
  "dateCreated": null
}

application/xml, text/xml

Sample:
<Delegate xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TS.DR.Resources.Delegates">
  <AddressComments i:nil="true" />
  <CanManageClients>false</CanManageClients>
  <CanManageDelegates>false</CanManageDelegates>
  <CanManageLocations>false</CanManageLocations>
  <Comments i:nil="true" />
  <DateCreated i:nil="true" />
  <DelegateGroupId>1</DelegateGroupId>
  <Email>jdoe@example.com</Email>
  <FirstName>John</FirstName>
  <Id>624</Id>
  <InheritGroupSecurity>false</InheritGroupSecurity>
  <LastName>Doe</LastName>
  <Phone>555-555-5124</Phone>
  <Role>Care Worker</Role>
  <SecuritySettings>
    <CanBookSubscriptions>false</CanBookSubscriptions>
    <CanBookTrips>true</CanBookTrips>
    <CanCancelTrips>false</CanCancelTrips>
    <CanEditCasualTrips>false</CanEditCasualTrips>
    <CanEditProfile>false</CanEditProfile>
    <CanEditSubscriptionTrips>false</CanEditSubscriptionTrips>
    <CanManagePassengerFeedback>false</CanManagePassengerFeedback>
    <CanViewProfile>true</CanViewProfile>
  </SecuritySettings>
  <Username>jdoe@example.com</Username>
</Delegate>