Przejdź do głównej zawartości
Wersja: 7.x

Webservice standard

YetiForce API for Webservice App. Type: WebserviceStandard (0.2)

Download OpenAPI specification:Download

Skip the /webservice fragment for connections via ApiProxy. There are two ways to connect to API, with or without rewrite, below are examples of both:

  • rewrite
    • CRM_URL/webservice/WebserviceStandard/Users/Login
    • CRM_URL/webservice/WebserviceStandard/Accounts/RecordRelatedList/117/Contacts
  • without rewrite
    • CRM_URL/webservice.php?_container=WebserviceStandard&module=Users&action=Login
    • CRM_URL/webservice.php?_container=WebserviceStandard&module=Accounts&action=RecordRelatedList&record=117&param=Contacts

Base module

Access to record methods

List of custom view

Gets a list of custom view

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Data of custom view

Gets data of custom view

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

cvId
required
integer
Example: 12

Custom view ID

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Get data about fields, blocks and inventory

Returns information about fields, blocks and inventory based on the selected module

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

x-response-params
Array of strings
Items Enum: "inventory" "blocks" "privileges" "dbStructure" "queryOperators"

The header contains information about additional data to be returned in the response [Json array]

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Get privileges for module

Gets the list of actions that the user has access to in the module

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Data for the record

Gets the details of a record

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

recordId
required
integer
Example: 116

Record id

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

x-raw-data
integer (Header - Get raw data)
Default: 1
Enum: 0 1

Get additional raw data

x-parent-id
integer (Header - Parent record id)
Default: 0
Enum: 0 1

Parent record id

x-fields-params
object (Custom field settings)
Example: {"password":{"showHiddenData":true}}

JSON array - list of fields to be returned in the specified way

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Edit record

Retrieves data for editing a record

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

recordId
required
integer
Example: 116

Record id

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Request Body schema:
required

Contents of the request contains an associative array with the data record.

object (General - Record edit details)

Record data in user format for edit view

Responses

Request samples

Content type
{
  • "field_name_1": "Tom",
  • "field_name_2": "Kowalski",
  • "assigned_user_id": 1,
  • "createdtime": "2014-09-24 20:51:12"
}

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Delete record

Changes the state of a record, moving it to the trash

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

recordId
required
integer
Example: 116

Record id

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": true
}

Create record

Create new record

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Request Body schema:
required

Contents of the request contains an associative array with the data record.

object (General - Record edit details)

Record data in user format for edit view

Responses

Request samples

Content type
{
  • "field_name_1": "Tom",
  • "field_name_2": "Kowalski",
  • "assigned_user_id": 1,
  • "createdtime": "2014-09-24 20:51:12"
}

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Record history

Gets the history of the record

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

recordId
required
integer
Example: 116

Record id

header Parameters
x-row-limit
integer
Example: 50

Get rows limit, default: 100

x-page
integer
Example: 1

Page number, default: 1

x-start-with
integer
Example: 5972

Show history from given ID

x-raw-data
integer (Header - Get raw data)
Default: 1
Enum: 0 1

Get additional raw data

x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Related list of records

Gets a list of related records

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

recordId
required
integer
Example: 116

Record id

relatedModuleName
required
string
Example: Contacts

Related module name

query Parameters
relationId
integer

Relation id

cvId
integer

Custom view id

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

x-raw-data
integer (Header - Get raw data)
Default: 1
Enum: 0 1

Get additional raw data

x-row-limit
integer
Example: 1000

Get rows limit, default: 100

x-row-offset
integer

Offset, default: 0

x-fields
Array of strings

JSON array in the list of fields to be returned in response

General - Condition for query generator (object) or General - Conditions for query generator (object) (General - Mix conditions for query generator)

Conditions [Json format]

x-only-column
integer
Enum: 0 1
Example: 1

Return only column names

object (Sort conditions)

Set the sorted results by columns [Json format]

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

List of records

Gets a list of records

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

query Parameters
General - Condition for query generator (object) or General - Conditions for query generator (object) (General - Mix conditions for query generator)

Conditions

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

x-raw-data
integer (Header - Get raw data)
Default: 1
Enum: 0 1

Get additional raw data

x-row-limit
integer
Example: 50

Get rows limit, default: 100

x-row-offset
integer

Offset, default: 0

x-row-count
integer
Enum: 0 1
Example: 1

Whether to get the number of records

x-fields
Array of strings

JSON array in the list of fields to be returned in response

General - Condition for query generator (object) or General - Conditions for query generator (object) (General - Mix conditions for query generator)

Conditions [Json format]

x-only-column
integer
Enum: 0 1
Example: 1

Return only column names

x-fields-info
integer
Enum: 0 1
Example: 1

Return additional field details

x-response-params
Array of strings
Items Enum: "privileges" "dbStructure" "queryOperators"

The header contains information about additional data to be returned in the response [Json array], depends on header x-response-params

x-parent-id
integer (Header - Parent record id)
Default: 0
Enum: 0 1

Parent record id

x-fields-params
object (Custom field settings)
Example: {"password":{"showHiddenData":true}}

JSON array - list of fields to be returned in the specified way

x-cv-id
integer
Example: 5

Custom view ID

object (Sort conditions)

Set the sorted results by columns [Json format]

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Related list of modules

Gets a list of related modules

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
moduleName
required
string
Example: Contacts

Module name

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Base actions

Access to user methods

Download files

Download files from the system

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Request Body schema:
required

Action parameters to download the file

module
required
string

Module name

actionName
required
string
Enum: "MultiImage" "DownloadFile"

Action name

record
required
integer

Record ID

field
string

Field name. Required for MultiImage action

key
string

Unique key for attachment. Required for MultiImage action

Responses

Request samples

Content type
No sample

Response samples

Content type
{
  • "status": 0,
  • "error": {
    }
}

The allowed actions of the module list

Get the permitted module list action, along with their translated action

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Users

Access to user methods

History of access activity data

Get user history of access activity

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

x-row-limit
integer
Example: 1000

Get rows limit, default: 50

x-row-offset
integer

Offset, default: 0

x-condition
object (General - Conditions for native query)
Example: {"column_name1":"searched value 1","column_name2":"searched value 2"}

Conditions [Json format]

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

User password change

User password change

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Request Body schema:
required

Input data

currentPassword
required
string (Current password)
newPassword
required
string (New password)

Responses

Request samples

Content type
No sample

Response samples

Content type
{
  • "status": 0,
  • "result": false
}

Login

Authenticate into the system

Authorizations:
(basicAuthApiKeyAuth)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

Request Body schema:
required

Input data format

userName
required
string

Webservice user name

password
required
string

Webservice user password

code
string

2FA TOTP code (optional property), Pass code length = 6, Code period = 30

object

Additional parameters sent by the user, extending the current settings, e.g. language

Responses

Request samples

Content type
No sample

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Logout user

Logout user out the system

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": true
}

Data for the user

Gets details about the user

Authorizations:
(basicAuthApiKeyAuthtoken)
path Parameters
userId
required
integer
Example: 116

User id

header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

x-raw-data
integer (Header - Get raw data)
Default: 1
Enum: 0 1

Get additional raw data

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Create user

Create new user

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Request Body schema:
required

Contents of the request contains an associative array with the user data.

object (General - User create details)

User data in user format for create view

Responses

Request samples

Content type
{
  • "user_name": "tom",
  • "first_name": "Tom",
  • "last_name": "Kowalski",
  • "roleid": "H38",
  • "password": "MyFunP@ssword",
  • "confirm_password": "MyFunP@ssword",
  • "email1": "my@email.com",
  • "language": "en-US"
}

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

List of users

Gets a list of all users

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

x-raw-data
integer (Header - Get raw data)
Default: 1
Enum: 0 1

Get additional raw data

x-row-limit
integer
Example: 1000

Get rows limit, default: 1000

x-row-offset
integer

Offset, default: 0

object (Sort conditions)

Set the sorted results by columns [Json format]

x-fields
Array of strings

JSON array in the list of fields to be returned in response

General - Condition for query generator (object) or General - Conditions for query generator (object) (General - Mix conditions for query generator)

Conditions [Json format]

x-parent-id
integer (Header - Parent record id)
Default: 0
Enum: 0 1

Parent record id

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

User password reset-Passwordchange

User password reset - Password change

Authorizations:
(basicAuthApiKeyAuth)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Request Body schema:
required

Input data

token
required
string

A one-time password reset token

password
required
string

New password

Responses

Request samples

Content type
No sample

Response samples

Content type
{
  • "status": 0,
  • "result": false
}

User password reset-Generating and sending a one-time token

User password reset - Generating and sending a one-time token

Authorizations:
(basicAuthApiKeyAuth)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Request Body schema:
required

Input data

userName
required
string

User name / email

Responses

Request samples

Content type
No sample

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

2FA details

Get two factor authentication details

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": {
    }
}

Activate 2FA

Activate two factor authentication

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": "string"
}

Disable 2FA

Disable two factor authentication

Authorizations:
(basicAuthApiKeyAuthtoken)
header Parameters
x-encrypted
integer (Header - Encrypted)
Default: 0
Enum: 0 1

Is the content request is encrypted

x-session-info
integer (Header - Get session life information)
Default: 1
Enum: 0 1

Get session life information

x-session-uptime
integer (Header - Whether to update session life)
Default: 0
Enum: 0 1

Whether to update session life

Responses

Response samples

Content type
{
  • "status": 0,
  • "result": true
}