Platform Subscription API

<back to all web services

SaveIntegration

Requires Authentication
The following routes are available for this service:
All Verbs/api/integration
import Foundation
import ServiceStack

public class SaveIntegration : Codable
{
    /**
    * The integration reference ID which is the gateway packet id.  If the value passed is empty, new packet record will be created.
    */
    // @ApiMember(DataType="Guid?", Description="The integration reference ID which is the gateway packet id.  If the value passed is empty, new packet record will be created.", Name="IntegrationId")
    public var integrationId:String

    /**
    * Name or title of the integration
    */
    // @ApiMember(DataType="string", Description="Name or title of the integration", Name="Title")
    public var title:String

    /**
    * Version information of the integration module.
    */
    // @ApiMember(DataType="IntegrationVersion", Description="Version information of the integration module.", Name="Version")
    public var version:IntegrationVersion

    /**
    * User who requested the integration
    */
    // @ApiMember(DataType="string", Description="User who requested the integration", Name="User")
    public var user:String

    /**
    * Local computer where the integration is performed on
    */
    // @ApiMember(DataType="string", Description="Local computer where the integration is performed on", Name="LocalComputer")
    public var localComputer:String

    /**
    * Windows version information
    */
    // @ApiMember(DataType="IntegrationWinVersion", Description="Windows version information", Name="WinVersion")
    public var winVersion:IntegrationWinVersion

    /**
    * Completed status of the integration
    */
    // @ApiMember(DataType="bool", Description="Completed status of the integration", Name="Completed")
    public var completed:Bool

    /**
    * Status of the integration.
    */
    // @ApiMember(DataType="string", Description="Status of the integration.", Name="Status")
    public var status:String

    /**
    * Start date and time of the integration.
    */
    // @ApiMember(DataType="DateTime", Description="Start date and time of the integration.", Name="StartTime")
    public var startTime:Date

    /**
    * End date and time of the integration.
    */
    // @ApiMember(DataType="DateTime", Description="End date and time of the integration.", Name="EndTime")
    public var endTime:Date

    /**
    * Settings XML being used in the integration.
    */
    // @ApiMember(DataType="IntegrationFileModel", Description="Settings XML being used in the integration.", Name="SettingsFile")
    public var settingsFile:IntegrationFileModel

    /**
    * File (xml) containing the results of the integration
    */
    // @ApiMember(DataType="IntegrationFileModel", Description="File (xml) containing the results of the integration", Name="ResultsFile")
    public var resultsFile:IntegrationFileModel

    /**
    * File (xml) containing the issues that were identified during integration
    */
    // @ApiMember(DataType="IntegrationFileModel", Description="File (xml) containing the issues that were identified during integration", Name="IssuesFile")
    public var issuesFile:IntegrationFileModel

    required public init(){}
}

public class IntegrationVersion : Codable
{
    public var major:Int
    public var minor:Int
    public var build:Int
    public var revision:Int

    required public init(){}
}

public class IntegrationWinVersion : Codable
{
    public var name:String
    public var version:String
    public var build:Int
    public var servicePack:String

    required public init(){}
}

public class IntegrationFileModel : Codable
{
    public var index:Int
    public var name:String
    public var content:String
    public var contentType:String
    public var fileSizeKB:Int
    public var blobUri:String
    public var createdDate:Date
    public var notes:String

    required public init(){}
}

// @ApiResponse(Description="Track integration result")
public class SaveIntegrationResponse : Codable
{
    public var integrationId:String
    public var responseStatus:ResponseStatus

    required public init(){}
}


Swift SaveIntegration 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.

POST /api/integration HTTP/1.1 
Host: production-eros-platform-apisubscription.azurewebsites.net 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	Title: String,
	Version: 
	{
		Major: 0,
		Minor: 0,
		Build: 0,
		Revision: 0
	},
	User: String,
	LocalComputer: String,
	WinVersion: 
	{
		Name: String,
		Version: String,
		Build: 0,
		ServicePack: String
	},
	Completed: False,
	Status: String,
	StartTime: 0001-01-01,
	EndTime: 0001-01-01,
	SettingsFile: 
	{
		index: 0,
		Name: String,
		Content: String,
		ContentType: String,
		FileSizeKB: 0,
		BlobUri: String,
		CreatedDate: 0001-01-01,
		Notes: String
	},
	ResultsFile: 
	{
		index: 0,
		Name: String,
		Content: String,
		ContentType: String,
		FileSizeKB: 0,
		BlobUri: String,
		CreatedDate: 0001-01-01,
		Notes: String
	},
	IssuesFile: 
	{
		index: 0,
		Name: String,
		Content: String,
		ContentType: String,
		FileSizeKB: 0,
		BlobUri: String,
		CreatedDate: 0001-01-01,
		Notes: String
	}
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	}
}