Employees

Company employees who have access to item8.

Fields summary

Field

Type

Read

Write

Filter

Order

Default

Req. for new

id

primary

int

email

email

string

status

enum

list

Active

name

string

string

role

enum

list

none

create_date

datetime

range

now

password

string

sps_id

string

null

Available options

Field: status

Current state of user. You can change it only via API methods.

Option

Description

Active

User is active and can sign in, but only if role is not none

Inactive

User cannot sign in, but administrator can activate them again.

Deleted

User cannot sign in and administrator cannot see them in web UI.

Field: role

Role of user for ACL.

Option

Description

none

User exists but can't sign in even if their status is Active.

administrator

Full access to all objects and actions in web UI.

advertiser_director

User can work with all agreements, all advertisers, all invoices and all reports.

advertiser_manager

User can work only with agreements, invoices and the profiles of advertisers which they are set as Account Manager.

affiliate_director

User can work with all agreements, all affiliates, all bills and all reports.

affiliate_manager

User can work only with agreements, bills and the profiles of affiliates which they are set as Account Manager.

financial_manager

User can work with all affiliates and advertisers, bills and invoices, agreements and check bills/invoices as paid.

sales_manager

User can work with agreements, affiliates and advertisers which they are set as Sales Manager.

get
Filter

https://api.CLIENT_ID.item8.io/v1/users
You can use filter conditions. See fields table above and documentation about item8 filters.
Request
Response
Headers
Item8-Api-Key
required
string
Authentication API key.
Query Parameters
filter
optional
object
Filter conditions. See field map above.
pagination
optional
object
Limit and page of filter result.
order
optional
object
Order by some field (asc|desc). See field map above.
200: OK
List of objects found in item8 by filter conditions. "data" will be empty if no objects match the conditions.
{
"status": "success",
"message": "",
"data": [
{
"id": 42,
"email": "john.smith@example.com",
"status": "Active",
"name": "John Smith",
"role": "affiliate_director",
"create_date": "2017-12-30 23:59:59",
"password": "*** hidden ***",
"sps_id": "1q2w3e4r5t6y"
}
]
}
403: Forbidden
If you don't have an access.
{
"status": "forbidden",
"message": "You don't have an access to filter action.",
"data": []
}

get
Get by ID

https://api.CLIENT_ID.item8.io/v1/users/:id
Find any user by id.
Request
Response
Path Parameters
id
required
int
Unique primary identifier of item8 object.
Headers
Item8-Api-Key
required
string
Authentication API key.
200: OK
{
"status": "success",
"message": "",
"data": {
"id": 42,
"email": "john.smith@example.com",
"status": "Active",
"name": "John Smith",
"role": "affiliate_director",
"create_date": "2017-12-30 23:59:59",
"password": "*** hidden ***",
"sps_id": "1q2w3e4r5t6y"
}
}
403: Forbidden
If you don't have an access.
{
"status": "forbidden",
"message": "You don't have an access to User.",
"data": []
}
404: Not Found
If user doesn't exist.
{
"status": "error",
"message": "User with id=42 not found.",
"data": []
}

post
Create

https://api.CLIENT_ID.item8.io/v1/users
Request to create new user in item8.
Request
Response
Headers
Item8-Api-Key
required
string
Authentication API key.
Form Data Parameters
email
required
string
User email/login.
name
required
string
User name for UI.
role
optional
string
Role of user for ACL. Use only available options, see above.
password
required
string
New user password to sign in web UI.
sps_id
optional
string
Unique user ID in your tracking system (ONLY for HasOffers).
200: OK
User has been created and you get the data as it is stored in item8.
{
"status": "success",
"message": "New user created.",
"data": {
"id": 42,
"email": "john.smith@example.com",
"status": "Active",
"name": "John Smith",
"role": "affiliate_director",
"create_date": "2017-12-30 23:59:59",
"password": "*** hidden ***",
"sps_id": "1q2w3e4r5t6y"
}
}
403: Forbidden
If you don't have an access.
{
"status": "forbidden",
"message": "You don't have an access to create action.",
"data": []
}

put
Update

https://api.CLIENT_ID.item8.io/v1/users/:id
Request to update existing user in item8.
Request
Response
Path Parameters
id
required
int
Unique primary identifier of item8 object.
Headers
Item8-Api-Key
required
string
Authentication API key.
Form Data Parameters
email
optional
string
User email/login.
name
optional
string
User name for UI.
role
optional
string
Role of user for ACL. Use only available options, see above.
password
optional
string
New user password to sign in web UI.
sps_id
optional
string
Unique user ID in your tracking system (ONLY for HasOffers).
200: OK
User has been updated and you get data as it is stored in item8.
{
"status": "success",
"message": "User updated successfully.",
"data": {
"id": 42,
"email": "john.smith@example.com",
"status": "Active",
"name": "John Smith",
"role": "affiliate_director",
"create_date": "2017-12-30 23:59:59",
"password": "*** hidden ***",
"sps_id": "1q2w3e4r5t6y"
}
}
403: Forbidden
If you don't have an access.
{
"status": "forbidden",
"message": "You don't have an access to update action.",
"data": []
}
500: Internal Server Error
Validator finds some problem in your request.
{
"status": "error",
"message": "Email is not valid.",
"data": []
}

put
Disable

https://api.CLIENT_ID.item8.io/v1/users/:id/disable
Make user inactive so they can't sign in.
Request
Response
Path Parameters
id
required
int
Unique primary identifier of item8 object.
Headers
Item8-Api-Key
required
string
Authentication API key.
Form Data Parameters
reason
optional
string
Reason why you disable the user Item8 saves the message in history. It should be empty or minimum 6 chars.
200: OK
User disabled.
{
"status": "success",
"message": "",
"data": {
"id": 42,
"email": "john.smith@example.com",
"status": "Active",
"name": "John Smith",
"role": "affiliate_director",
"create_date": "2017-12-30 23:59:59",
"password": "*** hidden ***",
"sps_id": "1q2w3e4r5t6y"
}
}

put
Activate

https://api.CLIENT_ID.item8.io/v1/users/:id/activate
Make user active so they can sign in and use item8.
Request
Response
Path Parameters
id
required
int
Unique primary identifier of item8 object.
Headers
Item8-Api-Key
required
string
Authentication API key.
Form Data Parameters
reason
optional
string
Reason why you activate user. Item8 saves the message in history. It should be empty or minimum 6 chars.
200: OK
User is active.
{
"status": "success",
"message": "",
"data": {
"id": 42,
"email": "john.smith@example.com",
"status": "Active",
"name": "John Smith",
"role": "affiliate_director",
"create_date": "2017-12-30 23:59:59",
"password": "*** hidden ***",
"sps_id": "1q2w3e4r5t6y"
}
}

delete
Delete

https://api.CLIENT_ID.item8.io/v1/users/:id
Delete existing user from item8.
Request
Response
Path Parameters
id
required
int
Unique primary identifier of item8 object.
Headers
Item8-Api-Key
required
string
Authentication API key.
Form Data Parameters
reason
optional
string
Reason why you delete user Item8 saves the message in history. It should be empty or minimum 6 chars.
200: OK
User has been deleted.
{
"status": "success",
"message": "User deleted successfully.",
"data": []
}
403: Forbidden
If you don't have an access.
{
"status": "forbidden",
"message": "You don't have an access to delete action.",
"data": []
}
500: Internal Server Error
if validator finds some problem in your request.
{
"status": "error",
"message": "Message of reason should be minimum 6 letters.",
"data": []
}