SupplierConnect Gateway API

<back to all web services

GetRequestActivity

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

Requires Authentication
The following routes are available for this service:
GET/api/activity
GET/api/activity/{lastrowversion}

export class SupplierConnectObjectReference
{
    public RmsTableContextId: string;
    public AlternateKey: string;
    public DataSourceInstanceId: string;

    public constructor(init?: Partial<SupplierConnectObjectReference>) { (Object as any).assign(this, init); }
}

export class SupplierConnectContactInfo
{
    public Id: string;
    public Name: string;
    public Email: string;
    public Phone: string;
    public ContactReference: SupplierConnectObjectReference;

    public constructor(init?: Partial<SupplierConnectContactInfo>) { (Object as any).assign(this, init); }
}

export class SupplierConnectProjectInfo
{
    public Id: string;
    public Name: string;
    public Reference: string;
    public Description: string;
    public Address: string;
    public HouseType: string;
    public Elevation: string;
    public Supervisor: SupplierConnectContactInfo;
    public CustomerName: string;
    public ProjectReference: SupplierConnectObjectReference;

    public constructor(init?: Partial<SupplierConnectProjectInfo>) { (Object as any).assign(this, init); }
}

export class SupplierConnectPurchaseOrderInfo
{
    public Id: string;
    public Reference: string;
    public Description: string;
    public ProjectId: string;
    public PurchaseOrderReference: SupplierConnectObjectReference;

    public constructor(init?: Partial<SupplierConnectPurchaseOrderInfo>) { (Object as any).assign(this, init); }
}

export class SupplierConnectActivityReference
{
    public Name: string;
    public Notes: string;

    public constructor(init?: Partial<SupplierConnectActivityReference>) { (Object as any).assign(this, init); }
}

export class SupplierConnectScheduleParams
{
    public Name: string;
    public Value: string;

    public constructor(init?: Partial<SupplierConnectScheduleParams>) { (Object as any).assign(this, init); }
}

export enum AttachmentType
{
    Url = 'Url',
    FileStream = 'FileStream',
}

export class EmailAttachment
{
    public FileName: string;
    public ContentType: string;
    public Path: string;
    public Url: string;
    public Length: number;
    public FileStream: string;
    public StreamContent: string;
    public AttachmentType: AttachmentType;
    public ProcessedAndUploadedAsBlob: boolean;

    public constructor(init?: Partial<EmailAttachment>) { (Object as any).assign(this, init); }
}

export class SupplierConnectSchedule
{
    public RequestId: string;
    public PreviousRequestId: string;
    public LicenseeId: string;
    public LicenseeName: string;
    public ScheduleDateTime: string;
    public Requester: SupplierConnectContactInfo;
    public Supplier: SupplierConnectContactInfo;
    public Project: SupplierConnectProjectInfo;
    public PurchaseOrder: SupplierConnectPurchaseOrderInfo;
    public Activity: SupplierConnectActivityReference;
    public Params: SupplierConnectScheduleParams[];
    public Attachments: EmailAttachment[];

    public constructor(init?: Partial<SupplierConnectSchedule>) { (Object as any).assign(this, init); }
}

export class ScheduleDetails extends SupplierConnectSchedule
{
    public ReferenceId: string;
    public Index: number;
    public StatusId: string;
    public Status: string;
    public StatusMessage: string;
    public RequestedBy: string;
    public RequestedDate?: string;
    public CommunicationId: string;

    public constructor(init?: Partial<ScheduleDetails>) { super(init); (Object as any).assign(this, init); }
}

// @ApiResponse(Description="Returns the list of the schedule requests for the given list of Ids")
export class GetSchedulesResponse
{
    public Success: boolean;
    public Message: string;
    public ScheduleRequests: ScheduleDetails[];
    public ResponseStatus: ResponseStatus;
    public LastRowVersion: string;

    public constructor(init?: Partial<GetSchedulesResponse>) { (Object as any).assign(this, init); }
}

/** @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 */
// @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")
export class GetRequestActivity
{
    /** @description Row version of the last/latest record processed/returned in the previous request */
    // @DataMember(Name="LastRowVersion")
    // @ApiMember(Description="Row version of the last/latest record processed/returned in the previous request", IsRequired=true, Name="LastRowVersion")
    public LastRowVersion: string;

    public constructor(init?: Partial<GetRequestActivity>) { (Object as any).assign(this, init); }
}

TypeScript GetRequestActivity DTOs

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

HTTP + JSV

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: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	Success: False,
	Message: String,
	ScheduleRequests: 
	[
		{
			Index: 0,
			Status: String,
			StatusMessage: String,
			RequestedBy: String,
			RequestedDate: 0001-01-01,
			LicenseeName: String,
			ScheduleDateTime: 0001-01-01,
			Requester: 
			{
				Name: String,
				Email: String,
				Phone: String,
				ContactReference: 
				{
					AlternateKey: String
				}
			},
			Supplier: 
			{
				Name: String,
				Email: String,
				Phone: String,
				ContactReference: 
				{
					AlternateKey: String
				}
			},
			Project: 
			{
				Name: String,
				Reference: String,
				Description: String,
				Address: String,
				HouseType: String,
				Elevation: String,
				Supervisor: 
				{
					Name: String,
					Email: String,
					Phone: String,
					ContactReference: 
					{
						AlternateKey: String
					}
				},
				CustomerName: String,
				ProjectReference: 
				{
					AlternateKey: String
				}
			},
			PurchaseOrder: 
			{
				Reference: String,
				Description: String,
				PurchaseOrderReference: 
				{
					AlternateKey: String
				}
			},
			Activity: 
			{
				Name: String,
				Notes: String
			},
			Params: 
			[
				{
					Name: String,
					Value: String
				}
			],
			Attachments: 
			[
				{
					FileName: String,
					ContentType: String,
					Path: String,
					Url: String,
					Length: 0,
					StreamContent: String,
					AttachmentType: Url,
					ProcessedAndUploadedAsBlob: False
				}
			]
		}
	],
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	},
	LastRowVersion: String
}