| GET | /api/activity | ||
|---|---|---|---|
| GET | /api/activity/{lastrowversion} |
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;
import com.google.gson.annotations.*;
import com.google.gson.reflect.*;
public class dtos
{
/**
* Retrieves a list of activities of SupplierConnect schedule(s) for a given time window. This will return SupplierConnect schedule request(s), and the associated other details such as statuses
*/
@Api(Description="Retrieves a list of activities of SupplierConnect schedule(s) for a given time window. This will return SupplierConnect schedule request(s), and the associated other details such as statuses")
public static class GetRequestActivity
{
/**
* Row version of the last/latest record processed/returned in the previous request
*/
@DataMember(Name="LastRowVersion")
@SerializedName("LastRowVersion")
@ApiMember(Description="Row version of the last/latest record processed/returned in the previous request", IsRequired=true, Name="LastRowVersion")
public String LastRowVersion = null;
public String getLastRowVersion() { return LastRowVersion; }
public GetRequestActivity setLastRowVersion(String value) { this.LastRowVersion = value; return this; }
}
@ApiResponse(Description="Returns the list of the schedule requests for the given list of Ids")
public static class GetSchedulesResponse
{
public Boolean Success = null;
public String Message = null;
public ArrayList<ScheduleDetails> ScheduleRequests = null;
public ResponseStatus ResponseStatus = null;
public String LastRowVersion = null;
public Boolean isSuccess() { return Success; }
public GetSchedulesResponse setSuccess(Boolean value) { this.Success = value; return this; }
public String getMessage() { return Message; }
public GetSchedulesResponse setMessage(String value) { this.Message = value; return this; }
public ArrayList<ScheduleDetails> getScheduleRequests() { return ScheduleRequests; }
public GetSchedulesResponse setScheduleRequests(ArrayList<ScheduleDetails> value) { this.ScheduleRequests = value; return this; }
public ResponseStatus getResponseStatus() { return ResponseStatus; }
public GetSchedulesResponse setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
public String getLastRowVersion() { return LastRowVersion; }
public GetSchedulesResponse setLastRowVersion(String value) { this.LastRowVersion = value; return this; }
}
public static class ScheduleDetails extends SupplierConnectSchedule
{
public UUID ReferenceId = null;
public Integer Index = null;
public UUID StatusId = null;
public String Status = null;
public String StatusMessage = null;
public String RequestedBy = null;
public Date RequestedDate = null;
public UUID CommunicationId = null;
public UUID getReferenceId() { return ReferenceId; }
public ScheduleDetails setReferenceId(UUID value) { this.ReferenceId = value; return this; }
public Integer getIndex() { return Index; }
public ScheduleDetails setIndex(Integer value) { this.Index = value; return this; }
public UUID getStatusId() { return StatusId; }
public ScheduleDetails setStatusId(UUID value) { this.StatusId = value; return this; }
public String getStatus() { return Status; }
public ScheduleDetails setStatus(String value) { this.Status = value; return this; }
public String getStatusMessage() { return StatusMessage; }
public ScheduleDetails setStatusMessage(String value) { this.StatusMessage = value; return this; }
public String getRequestedBy() { return RequestedBy; }
public ScheduleDetails setRequestedBy(String value) { this.RequestedBy = value; return this; }
public Date getRequestedDate() { return RequestedDate; }
public ScheduleDetails setRequestedDate(Date value) { this.RequestedDate = value; return this; }
public UUID getCommunicationId() { return CommunicationId; }
public ScheduleDetails setCommunicationId(UUID value) { this.CommunicationId = value; return this; }
}
public static class SupplierConnectSchedule
{
public UUID RequestId = null;
public UUID PreviousRequestId = null;
public UUID LicenseeId = null;
public String LicenseeName = null;
public Date ScheduleDateTime = null;
public SupplierConnectContactInfo Requester = null;
public SupplierConnectContactInfo Supplier = null;
public SupplierConnectProjectInfo Project = null;
public SupplierConnectPurchaseOrderInfo PurchaseOrder = null;
public SupplierConnectActivityReference Activity = null;
public ArrayList<SupplierConnectScheduleParams> Params = null;
public ArrayList<EmailAttachment> Attachments = null;
public UUID getRequestId() { return RequestId; }
public SupplierConnectSchedule setRequestId(UUID value) { this.RequestId = value; return this; }
public UUID getPreviousRequestId() { return PreviousRequestId; }
public SupplierConnectSchedule setPreviousRequestId(UUID value) { this.PreviousRequestId = value; return this; }
public UUID getLicenseeId() { return LicenseeId; }
public SupplierConnectSchedule setLicenseeId(UUID value) { this.LicenseeId = value; return this; }
public String getLicenseeName() { return LicenseeName; }
public SupplierConnectSchedule setLicenseeName(String value) { this.LicenseeName = value; return this; }
public Date getScheduleDateTime() { return ScheduleDateTime; }
public SupplierConnectSchedule setScheduleDateTime(Date value) { this.ScheduleDateTime = value; return this; }
public SupplierConnectContactInfo getRequester() { return Requester; }
public SupplierConnectSchedule setRequester(SupplierConnectContactInfo value) { this.Requester = value; return this; }
public SupplierConnectContactInfo getSupplier() { return Supplier; }
public SupplierConnectSchedule setSupplier(SupplierConnectContactInfo value) { this.Supplier = value; return this; }
public SupplierConnectProjectInfo getProject() { return Project; }
public SupplierConnectSchedule setProject(SupplierConnectProjectInfo value) { this.Project = value; return this; }
public SupplierConnectPurchaseOrderInfo getPurchaseOrder() { return PurchaseOrder; }
public SupplierConnectSchedule setPurchaseOrder(SupplierConnectPurchaseOrderInfo value) { this.PurchaseOrder = value; return this; }
public SupplierConnectActivityReference getActivity() { return Activity; }
public SupplierConnectSchedule setActivity(SupplierConnectActivityReference value) { this.Activity = value; return this; }
public ArrayList<SupplierConnectScheduleParams> getParams() { return Params; }
public SupplierConnectSchedule setParams(ArrayList<SupplierConnectScheduleParams> value) { this.Params = value; return this; }
public ArrayList<EmailAttachment> getAttachments() { return Attachments; }
public SupplierConnectSchedule setAttachments(ArrayList<EmailAttachment> value) { this.Attachments = value; return this; }
}
public static class SupplierConnectContactInfo
{
public UUID Id = null;
public String Name = null;
public String Email = null;
public String Phone = null;
public SupplierConnectObjectReference ContactReference = null;
public UUID getId() { return Id; }
public SupplierConnectContactInfo setId(UUID value) { this.Id = value; return this; }
public String getName() { return Name; }
public SupplierConnectContactInfo setName(String value) { this.Name = value; return this; }
public String getEmail() { return Email; }
public SupplierConnectContactInfo setEmail(String value) { this.Email = value; return this; }
public String getPhone() { return Phone; }
public SupplierConnectContactInfo setPhone(String value) { this.Phone = value; return this; }
public SupplierConnectObjectReference getContactReference() { return ContactReference; }
public SupplierConnectContactInfo setContactReference(SupplierConnectObjectReference value) { this.ContactReference = value; return this; }
}
public static class SupplierConnectObjectReference
{
public UUID RmsTableContextId = null;
public String AlternateKey = null;
public UUID DataSourceInstanceId = null;
public UUID getRmsTableContextId() { return RmsTableContextId; }
public SupplierConnectObjectReference setRmsTableContextId(UUID value) { this.RmsTableContextId = value; return this; }
public String getAlternateKey() { return AlternateKey; }
public SupplierConnectObjectReference setAlternateKey(String value) { this.AlternateKey = value; return this; }
public UUID getDataSourceInstanceId() { return DataSourceInstanceId; }
public SupplierConnectObjectReference setDataSourceInstanceId(UUID value) { this.DataSourceInstanceId = value; return this; }
}
public static class SupplierConnectProjectInfo
{
public UUID Id = null;
public String Name = null;
public String Reference = null;
public String Description = null;
public String Address = null;
public String HouseType = null;
public String Elevation = null;
public SupplierConnectContactInfo Supervisor = null;
public String CustomerName = null;
public SupplierConnectObjectReference ProjectReference = null;
public UUID getId() { return Id; }
public SupplierConnectProjectInfo setId(UUID value) { this.Id = value; return this; }
public String getName() { return Name; }
public SupplierConnectProjectInfo setName(String value) { this.Name = value; return this; }
public String getReference() { return Reference; }
public SupplierConnectProjectInfo setReference(String value) { this.Reference = value; return this; }
public String getDescription() { return Description; }
public SupplierConnectProjectInfo setDescription(String value) { this.Description = value; return this; }
public String getAddress() { return Address; }
public SupplierConnectProjectInfo setAddress(String value) { this.Address = value; return this; }
public String getHouseType() { return HouseType; }
public SupplierConnectProjectInfo setHouseType(String value) { this.HouseType = value; return this; }
public String getElevation() { return Elevation; }
public SupplierConnectProjectInfo setElevation(String value) { this.Elevation = value; return this; }
public SupplierConnectContactInfo getSupervisor() { return Supervisor; }
public SupplierConnectProjectInfo setSupervisor(SupplierConnectContactInfo value) { this.Supervisor = value; return this; }
public String getCustomerName() { return CustomerName; }
public SupplierConnectProjectInfo setCustomerName(String value) { this.CustomerName = value; return this; }
public SupplierConnectObjectReference getProjectReference() { return ProjectReference; }
public SupplierConnectProjectInfo setProjectReference(SupplierConnectObjectReference value) { this.ProjectReference = value; return this; }
}
public static class SupplierConnectPurchaseOrderInfo
{
public UUID Id = null;
public String Reference = null;
public String Description = null;
public UUID ProjectId = null;
public SupplierConnectObjectReference PurchaseOrderReference = null;
public UUID getId() { return Id; }
public SupplierConnectPurchaseOrderInfo setId(UUID value) { this.Id = value; return this; }
public String getReference() { return Reference; }
public SupplierConnectPurchaseOrderInfo setReference(String value) { this.Reference = value; return this; }
public String getDescription() { return Description; }
public SupplierConnectPurchaseOrderInfo setDescription(String value) { this.Description = value; return this; }
public UUID getProjectId() { return ProjectId; }
public SupplierConnectPurchaseOrderInfo setProjectId(UUID value) { this.ProjectId = value; return this; }
public SupplierConnectObjectReference getPurchaseOrderReference() { return PurchaseOrderReference; }
public SupplierConnectPurchaseOrderInfo setPurchaseOrderReference(SupplierConnectObjectReference value) { this.PurchaseOrderReference = value; return this; }
}
public static class SupplierConnectActivityReference
{
public String Name = null;
public String Notes = null;
public String getName() { return Name; }
public SupplierConnectActivityReference setName(String value) { this.Name = value; return this; }
public String getNotes() { return Notes; }
public SupplierConnectActivityReference setNotes(String value) { this.Notes = value; return this; }
}
public static class SupplierConnectScheduleParams
{
public String Name = null;
public String Value = null;
public String getName() { return Name; }
public SupplierConnectScheduleParams setName(String value) { this.Name = value; return this; }
public String getValue() { return Value; }
public SupplierConnectScheduleParams setValue(String value) { this.Value = value; return this; }
}
public static class EmailAttachment
{
public String FileName = null;
public String ContentType = null;
public String Path = null;
public String Url = null;
public Long Length = null;
public InputStream FileStream = null;
public String StreamContent = null;
public AttachmentType AttachmentType = null;
public Boolean ProcessedAndUploadedAsBlob = null;
public String getFileName() { return FileName; }
public EmailAttachment setFileName(String value) { this.FileName = value; return this; }
public String getContentType() { return ContentType; }
public EmailAttachment setContentType(String value) { this.ContentType = value; return this; }
public String getPath() { return Path; }
public EmailAttachment setPath(String value) { this.Path = value; return this; }
public String getUrl() { return Url; }
public EmailAttachment setUrl(String value) { this.Url = value; return this; }
public Long getLength() { return Length; }
public EmailAttachment setLength(Long value) { this.Length = value; return this; }
public InputStream getFileStream() { return FileStream; }
public EmailAttachment setFileStream(InputStream value) { this.FileStream = value; return this; }
public String getStreamContent() { return StreamContent; }
public EmailAttachment setStreamContent(String value) { this.StreamContent = value; return this; }
public AttachmentType getAttachmentType() { return AttachmentType; }
public EmailAttachment setAttachmentType(AttachmentType value) { this.AttachmentType = value; return this; }
public Boolean isProcessedAndUploadedAsBlob() { return ProcessedAndUploadedAsBlob; }
public EmailAttachment setProcessedAndUploadedAsBlob(Boolean value) { this.ProcessedAndUploadedAsBlob = value; return this; }
}
public static enum AttachmentType
{
Url,
FileStream;
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /api/activity HTTP/1.1 Host: production-eros-gateway-api-supplierconnect.azurewebsites.net Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length
<GetSchedulesResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Eros.Subtle.Dvaravartman.SupplierConnect.Model.APIModels">
<LastRowVersion>String</LastRowVersion>
<Message>String</Message>
<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>
<ScheduleRequests>
<ScheduleDetails>
<Activity xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">
<Name>String</Name>
<Notes>String</Notes>
</Activity>
<Attachments xmlns:d4p1="http://schemas.datacontract.org/2004/07/Eros.Saguna.Common.Library" xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">
<d4p1:EmailAttachment>
<d4p1:AttachmentType>Url</d4p1:AttachmentType>
<d4p1:ContentType>String</d4p1:ContentType>
<d4p1:FileName>String</d4p1:FileName>
<d4p1:FileStream xmlns:d6p1="http://schemas.datacontract.org/2004/07/System.IO" i:nil="true" />
<d4p1:Length>0</d4p1:Length>
<d4p1:Path>String</d4p1:Path>
<d4p1:ProcessedAndUploadedAsBlob>false</d4p1:ProcessedAndUploadedAsBlob>
<d4p1:StreamContent>String</d4p1:StreamContent>
<d4p1:Url>String</d4p1:Url>
</d4p1:EmailAttachment>
</Attachments>
<LicenseeId xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">00000000-0000-0000-0000-000000000000</LicenseeId>
<LicenseeName xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">String</LicenseeName>
<Params xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">
<SupplierConnectScheduleParams>
<Name>String</Name>
<Value>String</Value>
</SupplierConnectScheduleParams>
</Params>
<PreviousRequestId xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">00000000-0000-0000-0000-000000000000</PreviousRequestId>
<Project xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">
<Address>String</Address>
<CustomerName>String</CustomerName>
<Description>String</Description>
<Elevation>String</Elevation>
<HouseType>String</HouseType>
<Id>00000000-0000-0000-0000-000000000000</Id>
<Name>String</Name>
<ProjectReference>
<AlternateKey>String</AlternateKey>
<DataSourceInstanceId>00000000-0000-0000-0000-000000000000</DataSourceInstanceId>
<RmsTableContextId>00000000-0000-0000-0000-000000000000</RmsTableContextId>
</ProjectReference>
<Reference>String</Reference>
<Supervisor>
<ContactReference>
<AlternateKey>String</AlternateKey>
<DataSourceInstanceId>00000000-0000-0000-0000-000000000000</DataSourceInstanceId>
<RmsTableContextId>00000000-0000-0000-0000-000000000000</RmsTableContextId>
</ContactReference>
<Email>String</Email>
<Id>00000000-0000-0000-0000-000000000000</Id>
<Name>String</Name>
<Phone>String</Phone>
</Supervisor>
</Project>
<PurchaseOrder xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">
<Description>String</Description>
<Id>00000000-0000-0000-0000-000000000000</Id>
<ProjectId>00000000-0000-0000-0000-000000000000</ProjectId>
<PurchaseOrderReference>
<AlternateKey>String</AlternateKey>
<DataSourceInstanceId>00000000-0000-0000-0000-000000000000</DataSourceInstanceId>
<RmsTableContextId>00000000-0000-0000-0000-000000000000</RmsTableContextId>
</PurchaseOrderReference>
<Reference>String</Reference>
</PurchaseOrder>
<RequestId xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">00000000-0000-0000-0000-000000000000</RequestId>
<Requester xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">
<ContactReference>
<AlternateKey>String</AlternateKey>
<DataSourceInstanceId>00000000-0000-0000-0000-000000000000</DataSourceInstanceId>
<RmsTableContextId>00000000-0000-0000-0000-000000000000</RmsTableContextId>
</ContactReference>
<Email>String</Email>
<Id>00000000-0000-0000-0000-000000000000</Id>
<Name>String</Name>
<Phone>String</Phone>
</Requester>
<ScheduleDateTime xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">0001-01-01T00:00:00</ScheduleDateTime>
<Supplier xmlns="http://schemas.datacontract.org/2004/07/Eros.Causal.Common.Entity">
<ContactReference>
<AlternateKey>String</AlternateKey>
<DataSourceInstanceId>00000000-0000-0000-0000-000000000000</DataSourceInstanceId>
<RmsTableContextId>00000000-0000-0000-0000-000000000000</RmsTableContextId>
</ContactReference>
<Email>String</Email>
<Id>00000000-0000-0000-0000-000000000000</Id>
<Name>String</Name>
<Phone>String</Phone>
</Supplier>
<CommunicationId>00000000-0000-0000-0000-000000000000</CommunicationId>
<Index>0</Index>
<ReferenceId>00000000-0000-0000-0000-000000000000</ReferenceId>
<RequestedBy>String</RequestedBy>
<RequestedDate>0001-01-01T00:00:00</RequestedDate>
<Status>String</Status>
<StatusId>00000000-0000-0000-0000-000000000000</StatusId>
<StatusMessage>String</StatusMessage>
</ScheduleDetails>
</ScheduleRequests>
<Success>false</Success>
</GetSchedulesResponse>