POST Document/Validate
Some tooltip text!
• 7 minutes to read
• 7 minutes to read
POST /api/v1/Document/Validate
Check that entity is ready for saving, return error messages by field.
Request Headers
Parameter Name | Description |
---|---|
Authorization | Supports 'Basic', 'SoTicket' and 'Bearer' schemes, depending on installation type. |
X-XSRF-TOKEN | If not using Authorization header, you must provide XSRF value from cookie or hidden input field |
Content-Type | Content-type of the request body: application/json , text/json , application/xml , text/xml , application/x-www-form-urlencoded , application/json-patch+json , application/merge-patch+json |
Accept | Content-type(s) you would like the response in: application/json , text/json , application/xml , text/xml , application/json-patch+json , application/merge-patch+json |
Accept-Language | Convert string references and multi-language values into a specified language (iso2) code. |
SO-Language | Convert string references and multi-language values into a specified language (iso2) code. Overrides Accept-Language value. |
SO-Culture | Number, date formatting in a specified culture (iso2 language) code. Partially overrides SO-Language/Accept-Language value. Ignored if no Language set. |
SO-TimeZone | Specify the timezone code that you would like date/time responses converted to. |
SO-AppToken | The application token that identifies the partner app. Used when calling Online WebAPI from a server. |
Request Body: documentEntity
Entity to be checked for errors.
Property Name | Type | Description |
---|---|---|
DocumentId | Integer | Primary key |
UpdatedBy | Associate | The person that last updated the appointment. |
CreatedBy | Associate | The person that first created the document. The property is read-only. |
Attention | String | Attention/salutation |
Header | String | Visible document name |
Name | String | File name |
OurRef | String | Our reference, searchable field from freetext search |
YourRef | String | Your reference |
CreatedDate | String | Registered when in UTC. |
UpdatedDate | String | Last updated when in UTC. |
Description | String | The actual text, max 2047 significant characters even though it is stored as a larger data type on some databases |
DocumentTemplate | DocumentTemplate | The template type of the document. |
Person | Person | A document may also be connected to a person; this must be a contact person registered on the current company. This does not mean however that a person is required. |
Associate | Associate | The owner of the document - the associate whose checklist the document is in. |
Contact | Contact | The contact associated with the document. It may also be null if no contact is associated with the document. |
Project | Project | A document may also be connected to a project, so you see the document both on the company card, and on the project card. This does not mean however that a project is required. |
Date | String | date + start time planned |
ExternalRef | String | External reference for document plugin to resolve document identity (Notes ID, e-mail message ID, whatever) |
Completed | String | Document Completed state. This is the part of the Status property. |
ActiveLinks | Integer | Number of active links to sale, document, appointment. |
Type | String | Is this a normal document or a mail-merge or report? |
Links | Array | List of all elements linked to the document. |
LockSemantics | String | |
Sale | Sale | A document may also be connected to a sale, so you see the document on the company card, on the project card and on the sale card. This does not mean however that a sale is required. May be null. |
SuggestedDocumentId | Integer | Suggested guide item that this document is an instance of (Note: NOT valid for appointments, they have their own link) |
Snum | Integer | The sequence number allocated from refcount on used template when creating the document |
UserDefinedFields | Object | Deprecated: Use {SuperOffice.CRM.Services.DocumentEntity.CustomFields} instead. Dictionary of user defined field data. The key string is the ProgId of the UdefField, or if the ProgId is empty it is a string of the format "SuperOffice:[UdefFieldIdentity]", e.g. "SuperOffice:1234" |
ExtraFields | Object | Deprecated: Use {SuperOffice.CRM.Services.DocumentEntity.CustomFields} instead. Extra fields added to the carrier. This could be data from Plug-ins, the foreign key system, external applications, etc. |
CustomFields | Object | Udef + Extra fields added to the carrier. Extra fields as defined by changes to database schema + user-defined fields as defined by admin. Custom fields combines user defined fields and extra fields into one bucket. The individual {SuperOffice.CRM.Services.DocumentEntity.ExtraFields} and |
PublishEventDate | String | Publish event date |
PublishTo | String | Publication valid to (inclusive) |
PublishFrom | String | Publication valid from (inclusive) |
IsPublished | Boolean | Publication is published |
VisibleFor | Array | The set of users or groups the record is visible for |
Response:object
OK
Response | Description |
---|---|
200 | OK |
Response body: object
Sample request
POST /api/v1/Document/Validate
Authorization: Basic dGplMDpUamUw
Accept: application/json; charset=utf-8
Accept-Language: *
Content-Type: application/json; charset=utf-8
{
"DocumentId": 268,
"UpdatedBy": null,
"CreatedBy": null,
"Attention": "doloribus",
"Header": "atque",
"Name": "Emard-Beatty",
"OurRef": "culpa",
"YourRef": "est",
"CreatedDate": "2015-04-21T17:54:08.2418376+02:00",
"UpdatedDate": "2023-02-04T17:54:08.2418376+01:00",
"Description": "Configurable intermediate concept",
"DocumentTemplate": null,
"Person": null,
"Associate": null,
"Contact": null,
"Project": null,
"Date": "2009-06-04T17:54:08.2418376+02:00",
"ExternalRef": "et",
"Completed": "Completed",
"ActiveLinks": 200,
"Type": "BookingForChecklist",
"Links": [
{
"EntityName": "Parker Group",
"Id": 769,
"Description": "Adaptive zero defect software",
"ExtraInfo": "sed",
"LinkId": 765
},
{
"EntityName": "Parker Group",
"Id": 769,
"Description": "Adaptive zero defect software",
"ExtraInfo": "sed",
"LinkId": 765
}
],
"LockSemantics": "Locking",
"Sale": null,
"SuggestedDocumentId": 646,
"Snum": 504,
"UserDefinedFields": {
"SuperOffice:1": "False",
"SuperOffice:2": "Miss Mable Fanny Gottlieb Sr."
},
"ExtraFields": {
"ExtraFields1": "accusantium",
"ExtraFields2": "perspiciatis"
},
"CustomFields": {
"CustomFields1": "ad",
"CustomFields2": "et"
},
"PublishEventDate": "2013-05-23T17:54:08.2418376+02:00",
"PublishTo": "2003-06-22T17:54:08.2418376+02:00",
"PublishFrom": "2005-08-03T17:54:08.2418376+02:00",
"IsPublished": false,
"VisibleFor": [
{
"VisibleId": 333,
"Visibility": "All",
"DisplayValue": "dolorum"
},
{
"VisibleId": 333,
"Visibility": "All",
"DisplayValue": "dolorum"
}
]
}
Sample response
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
"1": "aut",
"2": "iure"
}