User Update

Description

This call allows you to update existing user information in the OGF system. You can only update user information for accounts you you have created.

URI

REST URI [GET]:
/v11.02/User.svc/Update?SessionId={sessionId}&FirstName={FirstName}&LastName={LastName}&PhoneNumber={PhoneNumber}&Gender={Male|Female}&IndiOgfn={IndiOgfn}&ShippingStreet1={ShippingStreet1}&ShippingStreet2={ShippingStreet2}&ShippingCity={ShippingCity}&ShippingStateProvince={ShippingStateProvince}&ShippingCountry={ShippingCountry}&ShippingPostalCode={ShippingPostalCode}&CreditCardName={CreditCardName}&CreditCardNumber={CreditCardNumber}&CreditCardExpiration={CreditCardExpiration}

Example

Request GET
http://wsdev.onegreatfamily.com/v11.02/User.svc/Update?sessionid=d0q53hnw0yx0mtnp2rlge0fs&FirstName=First+Name&LastName=Surname&PhoneNumber=123-555-5555&Gender=Male&IndiOgfn=123456789&ShippingStreet1=address1&ShippingStreet2=Address2&ShippingCity=city&ShippingStateProvince=state&ShippingCountry=China&ShippingPostalCode=123456
Success Response Payload
<Result xmlns="http://schemas.datacontract.org/2004/07/OGF.WS.Data" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
	<Code>0</Code>
	<Message>Success</Message>
	<Value i:nill="true"></Value>
</Result>
Failed Response Payload
<Result xmlns="http://schemas.datacontract.org/2004/07/OGF.WS.Data">
	<Code>19407</Code>
	<Message>The user could not be found.</Message> 
</Result>
Fault Response Payload
<RestFault xmlns="http://schemas.datacontract.org/2004/07/OGF.WS.Data">
	<ErrorCode>551</ErrorCode>
	<FaultMessage>An unhandled exception has occurred</FaultMessage>
</RestFault>

Query String Parameters

Name Description Required

SessionId

The current session Id

Type: string

Default: None

Yes

FirstName

The users first name

Type: String

Constraints: Must be less than 20 characters

No

LastName

The users last name

Type: String

Constraints: Must be less than 30 characters

No

Gender

The users gender

Type: String

Constraints: Must be Male or Female

No

IndiOgfn

This is the Ogfn of the Indi record that represents this user

Type: UInt64

Constraints: Must be a valid number for a valid indi

No

PhoneNumber

The users phone number

Type: String

Constraints: Must be less than 25 characters not including dashes or spaces.

No

ShippingStreet1

Street Address First Part

Type: String

Constraints: Must be less than 25 characters

No

ShippingStreet2

Street Address Second Part

Type: String

Constraints: Must be less than 25 characters

No

ShippingCity

The City Name

Type: String

Constraints: Must be less than 40 characters

No

ShippingStateProvince

The State or Province

Type: String

Constraints: Must be less than 20 characters

No

ShippingCountry

The Country

Type: String

Constraints: Must be less than 30 characters

No

ShippingPostalCode

The Postalcode/Zipcode

Type: String

Constraints: Must be less than 15 characters

No

CreditCardName

Name that's on the card

Type: String

Constraints: Must be less than 50 characters

No

CreditCardNumber

Credit card number

Type: String

Constraints: Consists of a 16 character string [0-9] no spaces or separators

No

CreditCardExpiration

The card expiration date

Type: String

Constraints: short date format of the form MM.YYYY  where MM is the Month and YYYY is the year

No

Response Elements

Name Description

Result

This operation returns a Result Entity

Type: Result

Result.Value

No Result.Value is returned for this call

Type: User

HTTP Status Code HTTP Status Code

The Web Server returns a status code which indicates if the operation was successful. Anything other than 200 should be regarded as a failure.

HTTP Status Code of 417

The Web Server threw an exception and contains a RestFault entity. Retrieve the RestFault from the Webexception response property.