POST project/createProject?Token={Token}
Create project in the system. Privilege "New" of licensed agenda "Projects.Projects" required. No record permissions restriction implemented.
Request Information
Authorization
- Authorization by token required
Availability
- Method can be used
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| Token |
The action is authorized by this token. Token should generated by calling action "POST login". Expiration time of each token is 20 seconds |
globally unique identifier |
Required |
Body Parameters
ProjectCreateReq| Name | Description | Type | Additional information |
|---|---|---|---|
| Code |
Unique identification of the project in the system |
string |
Required String length: inclusive between 0 and 100 |
| Name |
The name of the project |
string |
Required String length: inclusive between 0 and 100 |
| Type |
The name of the project type |
string |
Required String length: inclusive between 0 and 100 |
| Name2 |
Alternative name of the project |
string |
String length: inclusive between 0 and 100 |
| Shortcut |
The project shortcut |
string |
String length: inclusive between 0 and 10 |
| Code2 |
Identification of the project |
string |
String length: inclusive between 0 and 100 |
| Description |
Project description |
string |
String length: inclusive between 0 and 4000 |
| PlannedFrom |
The scheduled begin of the project in format "yyyy-MM-ddTHH:mi:ss". |
date |
Data type: Date |
| PlannedTo |
The scheduled end of the project in format "yyyy-MM-ddTHH:mi:ss". |
date |
Data type: Date |
| Started |
The real begin date of the project in format "yyyy-MM-ddTHH:mi:ss". |
date |
Data type: Date |
| Finished |
The real end date of the project in format "yyyy-MM-ddTHH:mi:ss". |
date |
Data type: Date |
| Closed |
The real closing date of the project in format "yyyy-MM-ddTHH:mi:ss". |
date |
Data type: Date |
| SuperiorProjectCode |
Identification of the superior project in the system |
string |
String length: inclusive between 0 and 100 |
| Street |
The address of project |
string |
String length: inclusive between 0 and 100 |
| HouseNr |
The address of project |
string |
String length: inclusive between 0 and 10 |
| City |
The address of project |
string |
String length: inclusive between 0 and 100 |
| PostalCode |
The address of project |
string |
String length: inclusive between 0 and 30 |
| PersonIDInCharge |
The identification of the official person in charge by using PersonalID |
string |
String length: inclusive between 0 and 100 |
| PersonIDResolver |
The identification of the resolver by using PersonalID |
string |
None. |
Request Formats
application/json
{"PersonIDResolver":"X0001","Code":"CODE 1001","Name":"Name of the project 1001","Type":"Name of the project Type 1001","Name2":null,"Shortcut":null,"Code2":null,"Description":"Description of the project 1001","PlannedFrom":"\/Date(1546326000000)\/","PlannedTo":"\/Date(1549004400000)\/","Started":"\/Date(1546498800000)\/","Finished":"\/Date(1548522000000)\/","Closed":"\/Date(1548572400000)\/","SuperiorProjectCode":"","Street":"Street 5","HouseNr":"HouseNr 5","City":"City 5","PostalCode":"ZIP 5","PersonIDInCharge":"X0004"}
application/xml
<Request> <PersonIDResolver>X0001</PersonIDResolver> <Code>CODE 1001</Code> <Name>Name of the project 1001</Name> <Type>Name of the project Type 1001</Type> <Description>Description of the project 1001</Description> <PlannedFrom>2019-01-01T08:00:00</PlannedFrom> <PlannedTo>2019-02-01T08:00:00</PlannedTo> <Started>2019-01-03T08:00:00</Started> <Finished>2019-01-26T18:00:00</Finished> <Closed>2019-01-27T08:00:00</Closed> <SuperiorProjectCode /> <Street>Street 5</Street> <HouseNr>HouseNr 5</HouseNr> <City>City 5</City> <PostalCode>ZIP 5</PostalCode> <PersonIDInCharge>X0004</PersonIDInCharge> </Request>
Response Information
Response Codes
| Http Code | Error Number | Description |
|---|---|---|
| 200 request succesfully done | 0 | Processed with result: ExecOK |
| 202 request accepted | 1291 | Request accepted but some participants [{0}] already exist in the system |
| 400 bad request | 1002 | Entry parameter missing or parameter bindigs failed |
| 401 unauthorized | 1000 | Token {0} not found |
| 401 unauthorized | 1001 | Token {0} already expired |
| 401 unauthorized | 1006 | Ip filter violated for ip client address [{0}] |
| 401 unauthorized | 1007 | Ip filter [{0}] parsing failed |
| 401 unauthorized | 1008 | Request rate policy violated for [{0}] |
| 403 server refuses fo fulfill the request | 1286 | Privilege New of agenda Projects.Projects violated for [{0}] |
| 403 server refuses fo fulfill the request | 1 | Db operation failed, agenda missing priviliges |
| 403 server refuses fo fulfill the request | 2 | Db operation failed, record missing priviliges |
| 403 server refuses fo fulfill the request | 3 | Db operation failed, Record duplicity |
| 403 server refuses fo fulfill the request | 4 | Db operation failed, already changed by another user |
| 403 server refuses fo fulfill the request | 5 | Db operation failed, already deleted by another user |
| 403 server refuses fo fulfill the request | 6 | Db operation failed, database data consistence violation |
| 403 server refuses fo fulfill the request | 7 | Db operation failed, operation can not be executed because another problems occured |
| 403 server refuses fo fulfill the request | 8 | Db operation failed, licence violation |
| 403 server refuses fo fulfill the request | 1285 | Unique key Project code {0} is not unique |
| 404 required resource does not exist on the server | 1287 | The key ProjectType.Name {0} is unknown |
| 404 required resource does not exist on the server | 1100 | PersonId [{0}] not found |
| 404 required resource does not exist on the server | 1288 | The superior Project.Code {0} not found |
| 415 unsupported Media Type | The request entity has a media type which the server or resource does not support. Only application/json and application/xml are supported | |
| 500 internal error | Server exception description |
Resource Description
BaseRespOfProjectCreateReq| Name | Description | Type | Additional information |
|---|---|---|---|
| Result | RequestResult |
None. |
|
| Request | ProjectCreateReq |
None. |
Response Formats
application/json
{"Result":{"Message":"Processed with result: ExecOK","Code":0,"ModelStateErr":null},"Request":{"PersonIDResolver":"X0001","Code":"CODE 1001","Name":"Name of the project 1001","Type":"Name of the project Type 1001","Name2":null,"Shortcut":null,"Code2":null,"Description":"Description of the project 1001","PlannedFrom":"\/Date(1546326000000)\/","PlannedTo":"\/Date(1549004400000)\/","Started":"\/Date(1546498800000)\/","Finished":"\/Date(1548522000000)\/","Closed":"\/Date(1548572400000)\/","SuperiorProjectCode":"","Street":"Street 5","HouseNr":"HouseNr 5","City":"City 5","PostalCode":"ZIP 5","PersonIDInCharge":"X0004"}}
application/xml
<Response>
<Result>
<Message>Processed with result: ExecOK</Message>
<Code>0</Code>
</Result>
<Request>
<PersonIDResolver>X0001</PersonIDResolver>
<Code>CODE 1001</Code>
<Name>Name of the project 1001</Name>
<Type>Name of the project Type 1001</Type>
<Description>Description of the project 1001</Description>
<PlannedFrom>2019-01-01T08:00:00</PlannedFrom>
<PlannedTo>2019-02-01T08:00:00</PlannedTo>
<Started>2019-01-03T08:00:00</Started>
<Finished>2019-01-26T18:00:00</Finished>
<Closed>2019-01-27T08:00:00</Closed>
<SuperiorProjectCode />
<Street>Street 5</Street>
<HouseNr>HouseNr 5</HouseNr>
<City>City 5</City>
<PostalCode>ZIP 5</PostalCode>
<PersonIDInCharge>X0004</PersonIDInCharge>
</Request>
</Response>