Trendsic Platform Service

<back to all web services

SafetyIncidentDetailRequest

Requires Authentication
The following routes are available for this service:
GET,OPTIONS/v1/safety/incidents/{SafetyIncidentID}
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;

public class dtos
{

    public static class SafetyIncidentDetailRequest
    {
        public Integer SafetyIncidentID = null;
        
        public Integer getSafetyIncidentID() { return SafetyIncidentID; }
        public SafetyIncidentDetailRequest setSafetyIncidentID(Integer value) { this.SafetyIncidentID = value; return this; }
    }

    public static class SafetyIncidentResponse
    {
        public ResponseStatus ResponseStatus = null;
        public SafetyIncident Incident = null;
        
        public ResponseStatus getResponseStatus() { return ResponseStatus; }
        public SafetyIncidentResponse setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
        public SafetyIncident getIncident() { return Incident; }
        public SafetyIncidentResponse setIncident(SafetyIncident value) { this.Incident = value; return this; }
    }

    public static class SafetyIncident
    {
        public Integer SafetyIncidentID = null;
        public UUID SafetyIncidentUID = null;
        public UUID BranchId = null;
        public Integer ProjectID = null;
        public String IncidentNo = null;
        public String IncidentType = null;
        public String Severity = null;
        public String Status = null;
        public String Title = null;
        public String Location = null;
        public String CrewLabel = null;
        public String Description = null;
        public String ReportedBy = null;
        public Boolean IsRecordable = null;
        public Date OccurredAt = null;
        public Date ClosedAt = null;
        public String SourceRef = null;
        public String CreatedBy = null;
        public Date CreatedAt = null;
        public Date UpdatedAt = null;
        public Integer DaysAgo = null;
        
        public Integer getSafetyIncidentID() { return SafetyIncidentID; }
        public SafetyIncident setSafetyIncidentID(Integer value) { this.SafetyIncidentID = value; return this; }
        public UUID getSafetyIncidentUID() { return SafetyIncidentUID; }
        public SafetyIncident setSafetyIncidentUID(UUID value) { this.SafetyIncidentUID = value; return this; }
        public UUID getBranchId() { return BranchId; }
        public SafetyIncident setBranchId(UUID value) { this.BranchId = value; return this; }
        public Integer getProjectID() { return ProjectID; }
        public SafetyIncident setProjectID(Integer value) { this.ProjectID = value; return this; }
        public String getIncidentNo() { return IncidentNo; }
        public SafetyIncident setIncidentNo(String value) { this.IncidentNo = value; return this; }
        public String getIncidentType() { return IncidentType; }
        public SafetyIncident setIncidentType(String value) { this.IncidentType = value; return this; }
        public String getSeverity() { return Severity; }
        public SafetyIncident setSeverity(String value) { this.Severity = value; return this; }
        public String getStatus() { return Status; }
        public SafetyIncident setStatus(String value) { this.Status = value; return this; }
        public String getTitle() { return Title; }
        public SafetyIncident setTitle(String value) { this.Title = value; return this; }
        public String getLocation() { return Location; }
        public SafetyIncident setLocation(String value) { this.Location = value; return this; }
        public String getCrewLabel() { return CrewLabel; }
        public SafetyIncident setCrewLabel(String value) { this.CrewLabel = value; return this; }
        public String getDescription() { return Description; }
        public SafetyIncident setDescription(String value) { this.Description = value; return this; }
        public String getReportedBy() { return ReportedBy; }
        public SafetyIncident setReportedBy(String value) { this.ReportedBy = value; return this; }
        public Boolean getIsRecordable() { return IsRecordable; }
        public SafetyIncident setIsRecordable(Boolean value) { this.IsRecordable = value; return this; }
        public Date getOccurredAt() { return OccurredAt; }
        public SafetyIncident setOccurredAt(Date value) { this.OccurredAt = value; return this; }
        public Date getClosedAt() { return ClosedAt; }
        public SafetyIncident setClosedAt(Date value) { this.ClosedAt = value; return this; }
        public String getSourceRef() { return SourceRef; }
        public SafetyIncident setSourceRef(String value) { this.SourceRef = value; return this; }
        public String getCreatedBy() { return CreatedBy; }
        public SafetyIncident setCreatedBy(String value) { this.CreatedBy = value; return this; }
        public Date getCreatedAt() { return CreatedAt; }
        public SafetyIncident setCreatedAt(Date value) { this.CreatedAt = value; return this; }
        public Date getUpdatedAt() { return UpdatedAt; }
        public SafetyIncident setUpdatedAt(Date value) { this.UpdatedAt = value; return this; }
        public Integer getDaysAgo() { return DaysAgo; }
        public SafetyIncident setDaysAgo(Integer value) { this.DaysAgo = value; return this; }
    }

}

Java SafetyIncidentDetailRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /v1/safety/incidents/{SafetyIncidentID} HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<SafetyIncidentResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <Incident>
    <BranchId>00000000-0000-0000-0000-000000000000</BranchId>
    <ClosedAt>0001-01-01T00:00:00</ClosedAt>
    <CreatedAt>0001-01-01T00:00:00</CreatedAt>
    <CreatedBy>String</CreatedBy>
    <CrewLabel>String</CrewLabel>
    <DaysAgo>0</DaysAgo>
    <Description>String</Description>
    <IncidentNo>String</IncidentNo>
    <IncidentType>String</IncidentType>
    <IsRecordable>false</IsRecordable>
    <Location>String</Location>
    <OccurredAt>0001-01-01T00:00:00</OccurredAt>
    <ProjectID>0</ProjectID>
    <ReportedBy>String</ReportedBy>
    <SafetyIncidentID>0</SafetyIncidentID>
    <SafetyIncidentUID>00000000-0000-0000-0000-000000000000</SafetyIncidentUID>
    <Severity>String</Severity>
    <SourceRef>String</SourceRef>
    <Status>String</Status>
    <Title>String</Title>
    <UpdatedAt>0001-01-01T00:00:00</UpdatedAt>
  </Incident>
  <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types">
    <d2p1:ErrorCode>String</d2p1:ErrorCode>
    <d2p1:Message>String</d2p1:Message>
    <d2p1:StackTrace>String</d2p1:StackTrace>
    <d2p1:Errors>
      <d2p1:ResponseError>
        <d2p1:ErrorCode>String</d2p1:ErrorCode>
        <d2p1:FieldName>String</d2p1:FieldName>
        <d2p1:Message>String</d2p1:Message>
        <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d2p1:Meta>
      </d2p1:ResponseError>
    </d2p1:Errors>
    <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:KeyValueOfstringstring>
        <d3p1:Key>String</d3p1:Key>
        <d3p1:Value>String</d3p1:Value>
      </d3p1:KeyValueOfstringstring>
    </d2p1:Meta>
  </ResponseStatus>
</SafetyIncidentResponse>