By Secret Code

Method Description

Invoked with a POST request. Operation name is set up via Maestra framework. Details of method invocation can be found here.

POST https://api.maestra.io/v3/operations/sync?endpointId={unique ID of site/mobile app/etc.}&operation={operation name}&deviceUUID={unique device ID}

Accept: application/xml
Content-Type: application/xml
Authorization: SecretKey {Secret Key, check with the manager if it's mandatory}

<operation>
  <customer>
    <ids>
      <webSiteUserId>{customer ID}</webSiteUserId>
    </ids>
    <email>{customer email}</email>
    <mobilePhone>{mobile number}</mobilePhone>
  </customer>
  <authentificationCode>{secret code}</authentificationCode>
</operation>

Sample Operation

POST https://api.maestra.io/v3/operations/async?endpointId=Maestra&operation=AuthenticateBySecretCode

Accept: application/xml
Content-Type: application/xml
Authorization: SecretKey 2a4wVO

<operation>
  <customer>
  	<mobilePhone>79001234567</mobilePhone>
  </customer>
  <authentificationCode>123456</authentificationCode>
</operation>

Response

<result>
  <status>Success</status>
</result>
<result>
    <status>ValidationError</status>
    <validationMessages>
        <validationMessage>
            <message>Validation code "123456" can't be found</message>
        </validationMessage>
    </validationMessages>
</result>