What is wrong with this record create

{
“resource”: [
{
“id”: 0,
“FirstName”: “Vineet”,
“LastName”: “Chauhan”,
“username”: “sdsds”,
“Email: "sdsds.sdsd@gmail.com
}
],
“ids”: [
0
],
“filter”: “string”,
“params”: [
“string”
]
}

I am getting a error response

{
“error”: {
“context”: null,
“message”: “No record(s) detected in request.”,
“code”: 400
}
}

As per the defination only resource is required - rest all values are optional.

RecordsRequest {
resource (Array[RecordRequest], optional): Array of records. ,
ids (Array[integer], optional): Array of record identifiers. ,
filter (string, optional): SQL or native filter to determine records where modifications will be applied. ,
params (Array[string], optional): Array of name-value pairs, used for parameter replacement on filters.
}

I think the JSON request help is really poor. Can you not insert the data in the table manually and check to see the JSON for that record - if you would want to insert that record programatically…

@Vineet_Chauhan the payload wasn’t using valid JSON. Please try using below payload in your POST:

{
“resource”: [{
“id”: 0,
“FirstName”: “Vineet”,
“LastName”: “Chauhan”,
“username”: “sdsds”,
“Email”: “sdsds.sdsd @gmail.com
}],
“ids”: [
0
],
“filter”: “string”,
“params”: [
“string”
]
}

1 Like