Platform API

<back to all web services

GetProjectContacts

Returns a projects contacts (customer and project connected).

Requires Authentication
The following routes are available for this service:
All Verbs/api/project/{ProjectId}/contacts
System.IO.InvalidDataException: MetaData is potentially malicious. Expected scalar value, Received: The altitude of an address - the altitude above sea level."
   at ServiceStack.NativeTypes.VbNet.VbNetGeneratorExtensions.SafeValue(String value)
   at ServiceStack.NativeTypes.VbNet.VbNetGeneratorExtensions.QuotedSafeValue(String value)
   at ServiceStack.NativeTypes.VbNet.VbNetGenerator.TypeValue(String type, String value)
   at ServiceStack.NativeTypes.VbNet.VbNetGenerator.AppendAttributes(StringBuilderWrapper sb, List`1 attributes)
   at ServiceStack.NativeTypes.VbNet.VbNetGenerator.AddProperties(StringBuilderWrapper sb, MetadataType type, Dictionary`2 explicitInterfacesMap, Boolean includeResponseStatus)
   at ServiceStack.NativeTypes.VbNet.VbNetGenerator.AppendType(StringBuilderWrapper& sb, MetadataType type, String lastNS, List`1 allTypes, CreateTypeOptions options)
   at ServiceStack.NativeTypes.VbNet.VbNetGenerator.GetCode(MetadataTypes metadata, IRequest request, INativeTypesMetadata nativeTypes)
   at ServiceStack.NativeTypes.LangGeneratorExtensions.g__Generate|1_0(ILangGenerator gen, <>c__DisplayClass1_0& )
   at ServiceStack.NativeTypes.LangGeneratorExtensions.GenerateSourceCode(MetadataTypes metadataTypes, MetadataTypesConfig typesConfig, String lang, IRequest req, Action`1 configure)
   at ServiceStack.NativeTypes.LangGeneratorExtensions.GenerateSourceCode(List`1 metadataTypes, String lang, IRequest req, Action`1 configure)
   at ServiceStack.Metadata.BaseMetadataHandler.d__12.MoveNext()

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/project/{ProjectId}/contacts HTTP/1.1 
Host: pfapi.pstpf.com.au 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	ProjectContacts: 
	[
		{
			ContactAlternateKey: String,
			RoleName: String,
			RoleAlternateKey: String,
			Contact: 
			{
				MaritalStatus: 00000000000000000000000000000000,
				Gender: 00000000000000000000000000000000,
				FirstName: String,
				MiddleName: String,
				Surname: String,
				FullName: String,
				ShortName: String,
				BirthDate: 0001-01-01,
				Title: String,
				Salutation: String,
				Abn: String,
				Acn: String,
				Arbn: String,
				TradingName: String,
				LegalName: String,
				Notes: String,
				EmploymentIndustry: String,
				EmploymentRole: String,
				EmploymentGeographicArea: String,
				DriversLicence: String,
				GstRegistered: False,
				RecordStatus: String,
				ContactRoles: 
				[
					{
						AlternateKey: String
					}
				],
				ContactDetails: 
				[
					{
						ContactMethodName: String,
						ContactAddress: 
						{
							Address: 
							{
								DistanceAway: 0,
								Latitude: 0,
								Longitude: 0,
								SuburbName: String,
								StateShortName: String,
								PostCode: String,
								CountryName: String,
								ISOCountryCode: String,
								LotNumber: String,
								SubUnit: String,
								BuildingNumber: String,
								StreetNumber: String,
								StreetName: String,
								AddressLineOne: String,
								AddressLineTwo: String,
								AddressFull: String,
								IsPhysical: False,
								Notes: String,
								AutoMapCoordinates: False,
								LocationCoordinates: 
								{
									Latitude: 0,
									Longitude: 0,
									Altitude: 0,
									Accuracy: 0,
									AltitudeAccuracy: 0,
									Heading: 0,
									Speed: 0,
									VerticalSpeed: 0
								}
							},
							IsPostal: False,
							IsPrimaryLocation: False,
							IsRegisteredLocation: False,
							SuburbName: String,
							StateName: String,
							CountryName: String
						},
						ContactPhone: 
						{
							CountryCode: String,
							AreaCode: String,
							LocalNumber: String
						},
						CountryId: 00000000000000000000000000000000,
						ContactDetails: String,
						Notes: String,
						ContactDetailsCode: String,
						OrderContactMethod: 0,
						IsPrimaryContactMethod: False,
						IsAddress: True
					}
				],
				CustomContentXML: String,
				BlobImageURLPrimary: String,
				BlobImageURLPrimaryThumbnail: String,
				PrimaryMobile: String,
				PrimaryEmail: String
			},
			Index: 0
		}
	],
	CustomerContacts: 
	[
		{
			ContactAlternateKey: String,
			RoleName: String,
			RoleAlternateKey: String,
			Contact: 
			{
				MaritalStatus: 00000000000000000000000000000000,
				Gender: 00000000000000000000000000000000,
				FirstName: String,
				MiddleName: String,
				Surname: String,
				FullName: String,
				ShortName: String,
				BirthDate: 0001-01-01,
				Title: String,
				Salutation: String,
				Abn: String,
				Acn: String,
				Arbn: String,
				TradingName: String,
				LegalName: String,
				Notes: String,
				EmploymentIndustry: String,
				EmploymentRole: String,
				EmploymentGeographicArea: String,
				DriversLicence: String,
				GstRegistered: False,
				RecordStatus: String,
				ContactRoles: 
				[
					{
						AlternateKey: String
					}
				],
				ContactDetails: 
				[
					{
						ContactMethodName: String,
						ContactAddress: 
						{
							Address: 
							{
								DistanceAway: 0,
								Latitude: 0,
								Longitude: 0,
								SuburbName: String,
								StateShortName: String,
								PostCode: String,
								CountryName: String,
								ISOCountryCode: String,
								LotNumber: String,
								SubUnit: String,
								BuildingNumber: String,
								StreetNumber: String,
								StreetName: String,
								AddressLineOne: String,
								AddressLineTwo: String,
								AddressFull: String,
								IsPhysical: False,
								Notes: String,
								AutoMapCoordinates: False,
								LocationCoordinates: 
								{
									Latitude: 0,
									Longitude: 0,
									Altitude: 0,
									Accuracy: 0,
									AltitudeAccuracy: 0,
									Heading: 0,
									Speed: 0,
									VerticalSpeed: 0
								}
							},
							IsPostal: False,
							IsPrimaryLocation: False,
							IsRegisteredLocation: False,
							SuburbName: String,
							StateName: String,
							CountryName: String
						},
						ContactPhone: 
						{
							CountryCode: String,
							AreaCode: String,
							LocalNumber: String
						},
						CountryId: 00000000000000000000000000000000,
						ContactDetails: String,
						Notes: String,
						ContactDetailsCode: String,
						OrderContactMethod: 0,
						IsPrimaryContactMethod: False,
						IsAddress: True
					}
				],
				CustomContentXML: String,
				BlobImageURLPrimary: String,
				BlobImageURLPrimaryThumbnail: String,
				PrimaryMobile: String,
				PrimaryEmail: String
			},
			Index: 0
		}
	]
}