Ascio Web Service v3

Java Axis CreateContact

Creating a contact. The contactHandle is returned in the contact object passed by reference.

CreateContactResponse CreateContact(SecurityHeaderDetails securityHeader,CreateContactRequest request)

Response codes

ResultCodeMessageValue
200OK
401Authorization failed
501Syntax error in parameters or arguments
506Required attribute missing in request

CreateContact Request

Property
request

CreateContactResponse

PropertyTypeDescription
CreateContactResult
Contact
ResultCodeExample: 1
ResultMessage
Errors

Used in Classes

Java Axis example

package ascio.v3.examples;
import com.ascio.www._2013._02.*;
import ascio.lib.*;

public class CreateContactExample {
	public static CreateContactResponse main() {
		AscioConfig config = new AscioConfig();
		V3 env = config.getTesting().getV3();

		KeyValue keyValue =  new KeyValue();
		keyValue.setKey("Title");
		keyValue.setValue("Mr.");

		ExtensionsKeyValue contactExtensions[] =  new ExtensionsKeyValue[]{keyValue};
		contactExtensions[0].setKey("Title");
		contactExtensions[0].setValue("Mrs.");

                            
                            
                        
		Contact contact =  new Contact();
		contact.setFirstName("John");
		contact.setLastName("Doe");
		contact.setOrgName("Ascio");
		contact.setAddress1("Address1Test");
		contact.setAddress2("Address2Test");
		contact.setCity("CityTest");
		contact.setState("StateTest");
		contact.setPostalCode("888349");
		contact.setCountryCode("DK");
		contact.setPhone("+45.123456789");
		contact.setFax("+45.987654321");
		contact.setEmail("administrator@ascio-test-domain.com");
		contact.setType("owner");
		contact.setDetails("DetailsTest");
		contact.setOrganisationNumber("OrganisationNumberTest");
		contact.setExtensions(contactExtensions);

                    
                        
                            
                            
                        
                    
                
		CreateContactRequest request =  new CreateContactRequest();
		request.setContact(contact);

		try {
			CreateContactResponse response = env.getClient().createContact(request);			
			System.out.println("response\n");
			System.out.println("CreateContact Code\t:" + response.getResultCode());
			System.out.println("CreateContact Message\t: " + response.getResultMessage());

			if(response.getResultCode() > 200){
				for(String error : response.getErrors()) {
					System.out.print(error);
				}	
			}		
			return response;
		} catch (Exception e) {
			System.out.print(e);
		}
		return new CreateContactResponse();package ascio.v3.examples;
import com.ascio.www._2013._02.*;
import ascio.lib.*;

public class CreateContactExample {
	public static CreateContactResponse main() {
		AscioConfig config = new AscioConfig();
		V3 env = config.getTesting().getV3();

		KeyValue keyValue =  new KeyValue();
		keyValue.setKey("Title");
		keyValue.setValue("Mr.");

		ExtensionsKeyValue contactExtensions[] =  new ExtensionsKeyValue[]{keyValue};
		contactExtensions[0].setKey("Title");
		contactExtensions[0].setValue("Mrs.");

		Contact contact =  new Contact();
		contact.setFirstName("John");
		contact.setLastName("Doe");
		contact.setOrgName("Ascio");
		contact.setAddress1("Address1Test");
		contact.setAddress2("Address2Test");
		contact.setCity("CityTest");
		contact.setState("StateTest");
		contact.setPostalCode("888349");
		contact.setCountryCode("DK");
		contact.setPhone("+45.123456789");
		contact.setFax("+45.987654321");
		contact.setEmail("administrator@ascio-test-domain.com");
		contact.setType("owner");
		contact.setDetails("DetailsTest");
		contact.setOrganisationNumber("OrganisationNumberTest");
		contact.setExtensions(contactExtensions);

		CreateContactRequest request =  new CreateContactRequest();
		request.setContact(contact);

		try {
			CreateContactResponse response = env.getClient().createContact(request);			
			System.out.println("response\n");
			System.out.println("CreateContact Code\t:" + response.getResultCode());
			System.out.println("CreateContact Message\t: " + response.getResultMessage());

			if(response.getResultCode() > 200){
				for(String error : response.getErrors()) {
					System.out.print(error);
				}	
			}		
			return response;
		} catch (Exception e) {
			System.out.print(e);
		}
		return new CreateContactResponse();
WSDL for AWS v3
https://aws.demo.ascio.com/v3/aws.wsdl (OTE)
https://aws.ascio.com/v3/aws.wsdl (Live)
Please configure the IP-Whitelisting in the portal/demo-portal.