EN
Español
English
Português
    Case Creation

    This operation creates a case and when it is created, it saves the attachments, both of the case, and of its additional fields; After saving them, delete the files from the temporary folder created for this purpose.

    Petition Details

    • Base URL: {host}/ASMSAPI/
    • Uri: api/v9/item
    • Type: POST
    • Required headings:

    • content-type: application/json
    • X-Authorization: Bearer {token}

    URL Description

    • {host}: It represents the domain of the environment in which the API is located.
    • ASMSAPI/: Fixed API prefix.
    • URI: Specific endpoint for the request.


    EXAMPLE URL:

    https://{host}/ASMSAPI/api/v9/item
    


    Parameters:

    Name Data type Obligatory Description
    applicantId Int No Case requester identifier.
    authorId Int No Identifier of the perpetrator of the case.
    categoryId Int Yes Case category identifier.
    cause String No Description of the root cause of the problem, applicable only when the item type (itemType) is 2, indicating that it is a problem.
    CiId Int No Configuration item (CI) identifier.
    companyId Int No Company identifier.
    consoleType String Yes The type of console used to create the case (Specialist= 1, Client = 2, Administrator= 3, CMDB=4).
    customerId Int No Customer ID.
    Description String No Case description, may include HTML content.
    groupId Int No Identifier of the specialist group associated with the case.
    impactId Int No Impact identifier.
    itemType Int Yes Case Type:
    1. Incident
    2. Problem
    3. Change
    4. Service Requirement
    13. Release
    itemVersion Int No Version of the case.
    locationId Int No Location identifier.
    modelId Int Yes Operating model identifier.
    priorityId Int No Priority identifier.
    projectId Int Yes Project ID.
    providerId Int No Supplier identifier.
    reasonId Int No Identifier of the reason.
    registryTypeId Int No Type of case record.
    responsibleId Int No Identifier of the person responsible for the case.
    serviceId Int Yes Service identifier.
    stateId Int Yes Initial case status identifier.
    subject String No Subject of the case.
    urgencyId Int No Urgency identifier
    listAdditionalField Array No List of additional fields in the case.
    TempItemId Int No Temporary identifier of the item. this must be negative. Example: -1

    Body of the petition

    {
    
    "categoryId": 623, "cause": null, "ciId": null, "companyId": 578,
    
    "consoleType": "specialist", "correctActions": null, "currentTime": 0, "customerId": null, "description": "Test postman ", "foregroundColorRgb": "", "followUpActions": null, "hasMoreInformation": false, "hasPendingSurvey": false, "estimatedCost": 0,
    
    "realCost": 0, "recomendations": null, "impactId": 7203, "incorrectActions": null, "instance": 1632253928839, "isFeeAvailable": true, "itemType": 4,
    
    "itemVersion": 0, "knownError": null, "majorProblem": null, "modelId": 70,
    
    "unitId": null, "priorityReason": "", "projectId": 19,
    
    "providerId": null,
    
    "reasonId": null, "registryTypeId": 7199, "serviceId": 140,
    
    "stateId": 267,
    
        "subject": "Prueba póstman",
    
        "surveyToken": "",
    
        "thirdParty": null,
    
        "transformed": false,
    
        "listAdditionalField": [
    
            {
    
                "boolValue": null,
    
                "catalogId": null,
    
                "dataSourceId": null,
    
                "dateValue": null,
    
                "description": "[ES] Nombre Aplicativo",             "enable": true,
    
                "fieldId": 977,
    
                "fieldType": 3,
    
                "fieldTypeName": "List",
    
                "floatValue": null,
    
               "identifier": "A001",
    
                "inputStream": null,
    
                "intValue": 118,
    
                "itemId": null,
    
                "mandatory": true,
    
                "name": "[ES] Software 1",
    
                "order": 1,
    
                "projectId": null,
    
                "stringValue": "Aranda Data Safe",
    
                "type": null,
    
                "url": null,
    
                "visible": true
    
            },
    
            {
    
                 "boolValue": null,
    
                 "catalogId": null,
    
                 "dataSourceId": null,
    
                 "dateValue": null,
    
                 "description": "[ES] Nombre Aplicativo",             "enable": true,
    
                 "fieldId": 978,
    
                 "fieldType": 3,
    
                 "fieldTypeName": "List",
    
                 "floatValue": null,
    
                 "identifier": "A002",
    
                 "inputStream": null,
    
                 "intValue": 146,
    
                 "itemId": null,
    
                 "mandatory": true,
    
                 "name": "[ES] Software 2",
    
                 "order": 2,
    
                 "projectId": null,
    
                 "stringValue": "Aranda Virtual Support",             "type": null,
    
                 "url": null,
    
                 "visible": true
    
             },
    
             {
    
                 "boolValue": null,
    
                 "catalogId": null,
    
                 "dataSourceId": null,
    
                 "dateValue": null,
    
                 "description": "[ES] Nombre Aplicativo",             "enable": true,
    
                 "fieldId": 979,
    
                 "fieldType": 3,
    
                 "fieldTypeName": "List",
    
                 "floatValue": null,
    
                 "identifier": "A003",
    
                 "inputStream": null,
    
                 "intValue": 156,
    
                 "itemId": null,
    
                 "mandatory": true,
    
                 "name": "[ES] Software 3",
    
                 "order": 3,
    
                 "projectId": null,
    
                 "stringValue": "Aranda Field Service",
    
                 "type": null,
    
                 "url": null,
    
                 "visible": true
    
             },
    
             {
    
                 "boolValue": null,
    
                 "catalogId": null,
    
                 "dataSourceId": null,
    
                 "dateValue": null,
    
                 "description": "[ES] Nombre Aplicativo",             "enable": true,
    
                 "fieldId": 980,
    
                 "fieldType": 3,
    
                 "fieldTypeName": "List",
    
                 "floatValue": null,
    
                 "identifier": "A004",
    
                 "inputStream": null,
    
                 "intValue": 176,
    
                 "itemId": null,
    
                 "mandatory": true,
    
                 "name": "[ES] Software 4",
    
                 "order": 4,
    
                 "projectId": null,
    
                 "stringValue": "Aranda Path Management",             "type": null,
    
                 "url": null,
    
                 "visible": true
    
             }
    
         ],
    
         "authorId": 4832,
    
        "tempItemId": -3
    
    }
    

    Answer

    {
    
          "id": 84486,
    
          "idByProject": "RF-84486-19-407613" }
    
    

    Response Parameters:

    Name Data type Description
    Id Int Case ID
    idByProject String Case identifier by project

    Error messages

    Code HTTP status Error Message
    400 BadRequest \r\nParameter Name: ConsoleType
    400 BadRequest \r\nParameter Name: ItemType
    400 BadRequest \r\nParameter Name: ListAdditionalField
    400 BadRequest \r\nParameter Name: TempItemId
    400 BadRequest InvalidItemType
    400 BadRequest ModelIdIsEmpty
    400 BadRequest RequestNeedsSomeArguments
    400 BadRequest StateIdIsEmpty
    403 Forbidden DoNotHavePermissionForThisAction
    500 InternalServerError FailureAddItem