Organizations API

Create organization

POST /rest/v2/subjects/organizations/

This method creates organization

Parameters

Name Description
organization[n_opf_id] Legal organizational form
organization[vc_code] Short name
organization[vc_eng_code] International short name
organization[vc_name] Full name
organization[vc_eng_name] International name
organization[vc_inn] Tax reference number
organization[vc_kpp] Tax registration reason code
organization[n_subj_state_id] Subject state
organization[n_firm_id] Firm
organization[t_tags] Tags list
organization[vc_rem] Commentary

Request

Headers

Accept: application/json
Content-Type: application/json

Route

POST /rest/v2/subjects/organizations/

Body

{
  "organization": {
    "n_opf_id": 1041,
    "vc_code": "Ангбанд Телеком",
    "vc_eng_code": "Angband Telecom",
    "vc_name": "ООО \"Ангбанд Телеком\"",
    "vc_eng_name": "Angband Telecom LLC",
    "vc_inn": "123412342",
    "vc_kpp": "111112345",
    "n_parent_subj_id": null,
    "n_subj_state_id": 2011,
    "n_firm_id": 100,
    "n_region_id": 40230101,
    "t_tags": [

    ],
    "vc_rem": null,
    "n_subj_group_id": 50152401
  }
}

Response

Headers

Content-Type: application/json; charset=utf-8

Status

201 Created

Body

{
  "organization": {
    "n_company_id": 93750801,
    "n_opf_id": 1041,
    "vc_opf_code": "ООО",
    "vc_opf_name": "Общество с ограниченной ответственностью",
    "vc_code": "Ангбанд Телеком",
    "vc_eng_code": "Angband Telecom",
    "vc_name": "ООО \"Ангбанд Телеком\"",
    "vc_eng_name": "Angband Telecom LLC",
    "vc_inn": "123412342",
    "vc_kpp": "111112345",
    "n_subject_id": 93750801,
    "n_subj_type_id": 1001,
    "n_parent_subj_id": null,
    "n_subj_state_id": 2011,
    "vc_subj_state_name": "Активен",
    "n_base_subject_id": 93750801,
    "n_firm_id": 100,
    "vc_firm": "Offline Telecom",
    "n_region_id": 40230101,
    "vc_region": "г. Москва",
    "n_owner_id": 100,
    "vc_subj_name": "ООО \"Ангбанд Телеком\"",
    "vc_subj_code": "Ангбанд Телеком",
    "t_tags": [

    ],
    "vc_tags": null,
    "vc_rem": null,
    "vc_code_upper": "АНГБАНД ТЕЛЕКОМ",
    "vc_name_upper": "ООО \"АНГБАНД ТЕЛЕКОМ\"",
    "vc_subj_code_upper": "АНГБАНД ТЕЛЕКОМ",
    "vc_subj_name_upper": "ООО \"АНГБАНД ТЕЛЕКОМ\"",
    "n_subj_group_id": 50152401,
    "vc_subj_group_name": "Корпоративные клиенты"
  },
  "navigation": {
    "self": "http://example.org/rest/v2/subjects/organizations/",
    "customers": [

    ],
    "addresses": "http://example.org/rest/v2/subjects/organizations/93750801/addresses",
    "organizations": "http://example.org/rest/v2/subjects/organizations"
  }
}