POST api/Timesheets/{id}/attachments

Adds the timesheet Attachments for a single timesheet

Request Information

URI Parameters

NameDescriptionTypeAdditional information
id

timesheet Id

integer

Required

Body Parameters

TimesheetAttachmentwithImage
NameDescriptionTypeAdditional information
AttachmentId

integer

None.

TimesheetId

integer

None.

ProductSummaryId

integer

None.

Filename

string

None.

Type

string

None.

Image

string

None.

Request Formats

application/json, text/json

Sample:
{
  "AttachmentId": 1,
  "TimesheetId": 2,
  "ProductSummaryId": 1,
  "Filename": "sample string 3",
  "Type": "sample string 4",
  "Image": "sample string 5"
}

text/xml

Sample:
<TimesheetAttachmentwithImage xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RandstadWebAPI.Models.DTO">
  <AttachmentId>1</AttachmentId>
  <Filename>sample string 3</Filename>
  <Image>sample string 5</Image>
  <ProductSummaryId>1</ProductSummaryId>
  <TimesheetId>2</TimesheetId>
  <Type>sample string 4</Type>
</TimesheetAttachmentwithImage>

multipart/form-data

Sample:
<TimesheetAttachmentwithImage xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RandstadWebAPI.Models.DTO"><AttachmentId>1</AttachmentId><Filename>sample string 3</Filename><Image>sample string 5</Image><ProductSummaryId>1</ProductSummaryId><TimesheetId>2</TimesheetId><Type>sample string 4</Type></TimesheetAttachmentwithImage>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

COMPLETEIntTimesheetIntervalId

TimesheetAttachment
NameDescriptionTypeAdditional information
AttachmentId

integer

None.

TimesheetId

integer

None.

ProductSummaryId

integer

None.

Filename

string

None.

OriginalFileName

string

None.

Type

string

None.

ThumbnailImage

string

None.

MIMEType

string

None.

Response Formats

application/json, text/json

Sample:
{
  "AttachmentId": 1,
  "TimesheetId": 2,
  "ProductSummaryId": 1,
  "Filename": "sample string 3",
  "OriginalFileName": "sample string 4",
  "Type": "sample string 5",
  "ThumbnailImage": "sample string 6",
  "MIMEType": "sample string 7"
}

text/xml

Sample:
<TimesheetAttachment xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RandstadWebAPI.Models.DTO">
  <AttachmentId>1</AttachmentId>
  <Filename>sample string 3</Filename>
  <MIMEType>sample string 7</MIMEType>
  <OriginalFileName>sample string 4</OriginalFileName>
  <ProductSummaryId>1</ProductSummaryId>
  <ThumbnailImage>sample string 6</ThumbnailImage>
  <TimesheetId>2</TimesheetId>
  <Type>sample string 5</Type>
</TimesheetAttachment>

multipart/form-data

Sample:
<TimesheetAttachment xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RandstadWebAPI.Models.DTO"><AttachmentId>1</AttachmentId><Filename>sample string 3</Filename><MIMEType>sample string 7</MIMEType><OriginalFileName>sample string 4</OriginalFileName><ProductSummaryId>1</ProductSummaryId><ThumbnailImage>sample string 6</ThumbnailImage><TimesheetId>2</TimesheetId><Type>sample string 5</Type></TimesheetAttachment>