Create Company
Request
Path;
/api/company/create
Method: POST
Basic creation information;
{
"name": "Test Company",
"user":{
"mail":"john_doe@gmail.com"
},
"subdomain_prefix":"john",
"account":{
"establishment":1,
"branch":1,
"user":3,
"expiration":15,
"start_date":"13.05.2022"
}
}
Optional
{
"parent_id": "1",
"name": "Test Company",
"working_type":"course",
"packet_type":"user" ,
"user":{
"username":"John",
"surname":"Doe",
"mail":"john_doe@gmail.com",
"phone":"5521234567"
},
"domain":"",
"subdomain_prefix":"john",
"account":{
"establishment":1,
"branch":1,
"user":3,
"student":0,
"expiration":15,
"start_date":"13.05.2022"
},
"country_slug": "tr",
"currency": "tl"
}
Parameter Descriptions
- parent_id:required, Seller main company or seller dealer id, if it is company it is 1,
- name: Establishment name of customer company, max 32 chars,
- working_type:optional, Now only "course",
- packet_type:optional, Now only "user",
- domain:optional, if the establishment wants to use own domain, it can set here, also the establishment must redirect the DNS,
- subdomain_prefix:required, it must be only letter and number and also -,_ can use, max char is 16
- user
- mail: required and max 32 chars
- username: optional and max 16 chars
- surname: optional and max 16 chars
- phone: optional and it must be real phone number
- account
- establishment:required, institute or company count, min: 1
- branch:required, branch count of customer,min: 1
- user:required, user count of customer,min: 1
- student:optional, student count of customer, it is default unlimited, but also it can set as a number, 0 is unlimited,
- expiration:required, month of active time of customer app,
- start_date:required, it must be bigger than today, and maximum 3 months further can be,
- country_slug:optional, this is important if the customer is working as international,
- currency:optional, default is TL, but any currency can be used in the app
Response
Successful result;