This is a developer preview of Kubbos API. It's in beta, so it's subject to changes. If you need any of the "Coming soon" API services documented as soon as possible. Contact Us!

#potentialpotentialCustomers.list
#potentialCustomers.findByID
#potentialCustomers.create
#potentialCustomers.update
#potentialCustomers.delete

potentialCustomers.list

Request

{
/* --- search criteria (optional) --- */
"number":"",
"name":"",
"tradeName":"",
"taxIDNumber":"",
"street1":"",
"street2":"",
"country":"",                   // id value from countries.listForSelect
"state":"",                     // id value from states.listForSelect
"city":"",
"postalCode":"",
"phone":"",
"phone2":"",
"fax":"",
"marketID":"",                  // id value from markets.list 
"areaID":"",                    // id value from areas.list
"paymentTypeID":"",             // id value from paymentType.list 
"dueTypeID":"",                 // id value from dueDateTypes.list
"remarks":"",
"potentialCreationDateFrom":"", // Date format DD/MM/AAAA
"potentialCreationDateTo":"",   // Date format DD/MM/AAAA
"customerSubscriptionNews":""   // Boolean
}

Response

{
    "data":     {
        "result": [        {
            "equivalenceSurchageEnabled": false,
            "version": 1,
            "street1": "C/ Pintor Rosales, 3",
            "email": "info@pinto.com",
            "URL": "www.pinto.com",
            "postalCode": "28002",
            "fax": "91.322.322",
            "id": "11582",
            "paymentTypeID": 900,
            "companyID": 11582,
            "marketID": 165,
            "dueTypeID": 1260000001007,
            "areaID": 158,
            "taxIDNumber": "F18237111",
            "name": "Almacenes Pinto",
            "tradeName": "Pinto",
            "companyName": "Almacenes Pinto",
            "number": 1,
            "companyNumber": 1,
            "remarks": "Bastante interesados en el producto",
            "country": "España",
            "city": "Madrid",
            "potentialCreationDate": "06/03/2011 00:00:00",
            "state": "Madrid",
            "phone": "91.111.111",
            "hasNewsletterSubscription": false
		},
		{
		.....
        }],
        "total": 5
    },
    "success": true
}

potentialCustomers.findByID

Request

{"id": "11582"}

Response

{
    "data":     {
        "equivalenceSurchageEnabled": false,
        "version": 1,
        "street1": "C/ Pintor Rosales, 3",
        "carrierID": 21,
        "email": "info@pinto.com",
        "URL": "www.pinto.com",
        "postalCode": "28002",
        "salesDiscount": 5,
        "lineDiscount": 2,
        "earlyPaymentDiscount": 10,
        "paymentDay": 10,
        "fax": "91.322.322",
        "id": "11582",
        "companyID": 11582,
        "paymentTypeID": 900,
        "marketID": 165,
        "priceListID": 1260000001435,
        "dueTypeID": 1260000001007,
        "areaID": 158,
        "taxIDNumber": "F18237111",
        "name": "Almacenes Pinto",
        "tradeName": "Pinto",
        "companyName": "Almacenes Pinto",
        "number": 1,
        "companyNumber": 1,
        "remarks": "Bastante interesados en el producto",
        "country": "ESP",
        "countryDescription": "España",
        "city": "Madrid",
        "freights": 1,
        "potentialCreationDate": "06/03/2011 00:00:00",
        "state": "28",
        "stateDescription": "Madrid",
        "phone": "91.111.111",
        "hasNewsletterSubscription": false
    },
    "success": true
}

potentialCustomers.create

Request

{
"number": " ",                      // If empty, a new one autonumeric is assigned
"name": "Almacenes Pinto",          // *Required
"tradeName": "Pinto",
"taxIDNumber": "F18237111",
"street1": "C/ Pintor Rosales, 3",
"street2": " ",
"country": "ESP",                   // id value from countries.listForSelect
"state": "28",                      // id value from states.listForSelect
"city": "Madrid",
"postalCode": "28002",
"phone": "91.111.111",
"phone2": " ",
"fax": "91.322.322",
"email": "info@pinto.com",
"URL": "www.pinto.com",
"marketID": "165",                  // id value from markets.list 
"areaID": "158",                    // id value from areas.list
"carrierID": "21",                  // id value from carriers.list
"freights": "1",                    // values: 1=Prepaid shipment, 2=Collect on Delivery
"remarks": "Bastante interesados en el producto",
"potentialCreationDate": "06/03/2011",
"hasNewsletterSubscription": "false",
"paymentTypeID": "900",             // id value from paymentType.list
"dueTypeID": "1260000001007",       // id value from dueDateTypes.list
"paymentDay": "10",
"equivalenceSurchageEnabled": "false",
"priceListID": "1260000001435",     // id value from itemsPriceLists.list
"lineDiscount": "2",
"salesDiscount": "5",
"earlyPaymentDiscount": "10"
}

Response

{
    "data":     {
        "errors": [],
        "messages": [        {
            "description": "Operación realizada correctamente",
            "id": "operation_success"
        }],
        "warns": []
    },
    "id": "11582",
    "success": true,
    "version": 0
}

potentialCustomers.update

Request

{
"name": "Almacenes Pinto",          // *Required
"tradeName": "Pinto",
"taxIDNumber": "F18237111",
"street1": "C/ Pintor Rosales, 3",
"street2": " ",
"country": "ESP",                   // id value from countries.listForSelect
"state": "28",                      // id value from states.listForSelect
"city": "Madrid",
"postalCode": "28002",
"phone": "91.111.111",
"phone2": " ",
"fax": "91.322.322",
"email": "info@pinto.com",
"URL": "www.pinto.com",
"marketID": "165",                  // id value from markets.list 
"areaID": "158",                    // id value from areas.list
"carrierID": "21",                  // id value from carriers.list
"freights": "1",                    // values: 1=Prepaid shipment, 2=Collect on Delivery
"remarks": "Bastante interesados en el producto",
"potentialCreationDate": "06/03/2011",
"hasNewsletterSubscription": "false",
"paymentTypeID": "900",             // id value from paymentType.list
"dueTypeID": "1260000001007",       // id value from dueDateTypes.list
"paymentDay": "10",
"equivalenceSurchageEnabled": "true",
"priceListID": "1260000001435",     // id value from itemsPriceLists.list
"lineDiscount": "2",
"salesDiscount": "5",
"earlyPaymentDiscount": " ",
"id": "11582",
"version": 0
}

Response

{
    "data":     {
        "errors": [],
        "messages": [        {
            "description": "Operación realizada correctamente",
            "id": "operation_success"
        }],
        "warns": []
    },
    "id": "11582",
    "success": true,
    "version": 1
}

potentialCustomers.delete

Request


{
"id": "11582",
"version": 1
}

Response

{
    "data":     {
        "errors": [],
        "messages": [        {
            "args": ["11582"],
            "description": "Operación realizada correctamente",
            "id": "operation_success"
        }],
        "warns": []
    },
    "success": true
}
  • No labels