Provision An End User

Calling this POST method will return you a User ID and Agent token.

You'll use the User ID to assign this User to a Company in a further step in this guide.

The Agent token is used by your end user to place into their Agent. This allows you to connect to that Agent and process data. Later, you'll use this token to retrieve an Endpoint ID, which uniquely identifies that user's QuickBooks Company file. You'll use that Endpoint ID in most requests you make on the API.

Below is the URL you'll call to begin the process.

https://api.propelware.com/v1/manage/user

Send this payload along in your request. This empty JSON structure tells Autofy more about the nature of your request, and will result in the same structure being populated and returned.

  • agentToken is the string that the user enters into the Agent to identify it.
  • companyId is an internal value used for support purposes, and can be left empty.
  • dateTimeCreated is the time at which the user was created.
  • externalId is an internal value used for support purposes, and can be left empty.
  • id is the ID that you populate in /manage/company
  • isActive is the current active status of your user - always set this to true
{
	"agentToken": "",
	"companyId": "",
	"dateTimeCreated": "",
	"externalId": "",
	"id": "",
	"isActive": true
}

Request:

curl --request POST \
  --url https://api.propelware.com/v1/manage/user \
  --header 'cache-control: no-cache' \
  --header 'content-type: application/json' \
  --header 'authorization: {YOUR_API_KEY}' \
  --data '{"agentToken":"","companyId":"","dateTimeCreated":"","externalId":"","id":"","isActive":true}'

Response:

All Autofy API responses have two top level nodes, meta, and the data you requested.

StatusCode will be 0 or 200 if the call was successfully processed against the QuickBooks Company file. Otherwise, it will be an error code.

Store agentToken for use with the Autofy Agent.

{
	"Meta": {
		"StatusCode": 200,
		"Severity": null,
		"Message": "Success"
	},
	"user": {
		"agentToken": "BI45538M6MSQG75TG6E76V63GQ3H",
		"companyId": "",
		"dateTimeCreated": "2016-09-14T19:56:21.3149021+00:00",
		"externalId": "",
		"id": "28bb12f7393944a7be956888900d1f05",
		"isActive": true
	}
}

What’s Next