PUT api/v1/admin/accounts/{id}

This method updates an existing account specified by the account Id in the URL. The system will check that the user has permission to update the account and that the account Id is valid. This method does not use all of the parameters of the Account model below. This method uses the following: Address, ContactNumber, Disclaimer, EmailAddress, FirstName, LanguageID, LastName, Logo, LogoName, Name, SMSPassword, SMSUsername, TimeZone, TwoFactorEnabled, Website

Request Information

URI Parameters

NameDescriptionTypeAdditional information
id

The Id of the account to update its details.

globally unique identifier

Required

Body Parameters

Either xml or json request.

Account
NameDescriptionTypeAdditional information
ID

The unique identifier for the account.

globally unique identifier

None.

AccountID

The unique identifier for the parent account.

globally unique identifier

None.

Address

The address of the account.

string

None.

AnyTimeBalance

The anytime balance of the account.

decimal number

None.

ContactNumber

The contact number for the account.

string

None.

DateCreated

The date the account was created

date

None.

DateModified

The date the account was last modified

date

None.

Disclaimer

The text that is displayed at the bottom of the advanced messages.

string

None.

EmailAddress

The main email address for the account.

string

Required

LanguageID

The default language Id for the account.

globally unique identifier

None.

LanguageName

The name of the language

string

None.

Location

The country of the account.

string

None.

Logo

Base64 encoded string containing the logo that is displayed on advanced messages

string

None.

LogoName

The name of the logo file that is displayed on the web interface

string

None.

Name

The company name of the account.

string

Required

OffPeakBalance

The off peak balance of the account.

decimal number

None.

SMSPassword

The password the account's 2sms account.

string

Required

SMSUsername

The username for the account's 2sms account.

string

Required

TimeZone

The default time zone for the account.

string

Required

TwoFactorEnabled

Determines if two factor authentication has been enabled on the account.

boolean

None.

URL

string

None.

Website

The URL of the website for the account.

string

None.

Request Formats

application/json, text/json

Sample:
{
  "ID": "b79186ea-ac90-4157-af9e-40ee6cacadcd",
  "AccountID": "fa17ae58-3814-40b6-8b57-a65817b53137",
  "Address": "sample string 2",
  "AnyTimeBalance": 1.1,
  "ContactNumber": "sample string 3",
  "DateCreated": "2018-06-18T20:39:50.3717276+00:00",
  "DateModified": "2018-06-18T20:39:50.3717276+00:00",
  "Disclaimer": "sample string 5",
  "EmailAddress": "sample string 6",
  "FirstName": "sample string 8",
  "LanguageID": "006a31f9-bcf9-4921-850f-9f4f68f0731e",
  "LanguageName": "sample string 10",
  "LastName": "sample string 11",
  "Location": "sample string 12",
  "Logo": "sample string 13",
  "LogoName": "sample string 14",
  "Name": "sample string 15",
  "OffPeakBalance": 1.1,
  "SMSPassword": "sample string 16",
  "SMSUsername": "sample string 17",
  "TimeZone": "sample string 18",
  "TwoFactorEnabled": true,
  "URL": "sample string 19",
  "Website": "sample string 21"
}

application/xml, text/xml

Sample:
<Account xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <ID>b79186ea-ac90-4157-af9e-40ee6cacadcd</ID>
  <AccountID>fa17ae58-3814-40b6-8b57-a65817b53137</AccountID>
  <Address>sample string 2</Address>
  <AnyTimeBalance>1.1</AnyTimeBalance>
  <ContactNumber>sample string 3</ContactNumber>
  <DateCreated>2018-06-18T20:39:50.3717276+00:00</DateCreated>
  <DateModified>2018-06-18T20:39:50.3717276+00:00</DateModified>
  <Disclaimer>sample string 5</Disclaimer>
  <EmailAddress>sample string 6</EmailAddress>
  <Enabled>true</Enabled>
  <FirstName>sample string 8</FirstName>
  <LanguageID>006a31f9-bcf9-4921-850f-9f4f68f0731e</LanguageID>
  <LanguageName>sample string 10</LanguageName>
  <LastName>sample string 11</LastName>
  <Location>sample string 12</Location>
  <Logo>sample string 13</Logo>
  <LogoName>sample string 14</LogoName>
  <Name>sample string 15</Name>
  <OffPeakBalance>1.1</OffPeakBalance>
  <SMSPassword>sample string 16</SMSPassword>
  <SMSUsername>sample string 17</SMSUsername>
  <TimeZone>sample string 18</TimeZone>
  <TwoFactorEnabled>true</TwoFactorEnabled>
  <URL>sample string 19</URL>
  <Users>
    <AccountUserInfo>
      <UserID>eeef43d0-69ae-4bfc-8109-8eed70ddcbe7</UserID>
      <Name>sample string 2</Name>
      <PermissionLevel>STANDARD_USER</PermissionLevel>
    </AccountUserInfo>
    <AccountUserInfo>
      <UserID>eeef43d0-69ae-4bfc-8109-8eed70ddcbe7</UserID>
      <Name>sample string 2</Name>
      <PermissionLevel>STANDARD_USER</PermissionLevel>
    </AccountUserInfo>
  </Users>
  <Validated>true</Validated>
  <Website>sample string 21</Website>
</Account>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

Status message of the request

ResponseOfObject
NameDescriptionTypeAdditional information
Error

Error

None.

ResponseData

ResponseDataOfObject

None.

Response Formats

application/json, text/json

Sample:
{
  "Error": {
    "ErrorCode": "sample string 1",
    "ErrorReason": "sample string 2"
  },
  "ResponseData": {
    "Identification": {
      "UserId": "sample string 1"
    },
    "Result": "sample string 1",
    "Detail": {}
  }
}

application/xml, text/xml

Sample:
<ResponseOfObject xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <Error>
    <ErrorCode>sample string 1</ErrorCode>
    <ErrorReason>sample string 2</ErrorReason>
  </Error>
  <ResponseData>
    <Result>sample string 1</Result>
    <Identification>
      <UserId>sample string 1</UserId>
    </Identification>
    <Detail />
  </ResponseData>
</ResponseOfObject>