URI /RESTfm/{database}/bulk/{layout} Create - POST

URI /RESTfm/{database}/bulk/{layout}

Creates new records in {database} and {layout} from the records provided. Returns the full data of all created records.

Optional query string parameters

RFMsuppressData Set flag to suppress 'data' section from response.
RFMscript=<name> URL encoded script name to be called after result set is generated and sorted.
RFMscriptParam=<string> URL encoded parameter string to pass to script.
RFMpreScript=<name> URL encoded script name to be called before performing the find and sorting the result set.
RFMpreScriptParam=<string> URL encoded parameter string to pass to pre-script.

Example message, URI and response

{
    "data": [
        {
            "Pcode": "9998",
            "Locality": "A New Location 1"
        },
        {
            "Pcode": "9999",
            "Locality": "A New Location 2"
        }
    ]
}
Example bulk JSON format CREATE message.

http://demo.restfm.com/RESTfm/postcodes/bulk/brief%20postcodes.json

{
    "meta": [
        {
            "recordID": "9913809"
        },
        {
            "recordID": "9913810"
        }
    ],
    "data": [
        {
            "Pcode": "9998",
            "Locality": "A New Location 1",
            "State": "",
            "Comments": ""
        },
        {
            "Pcode": "9999",
            "Locality": "A New Location 2",
            "State": "",
            "Comments": ""
        }
    ],
    "info": {
        "X-RESTfm-Version": "3.0.0beta\/r420",
        "X-RESTfm-Protocol": "4",
        "X-RESTfm-Status": 200,
        "X-RESTfm-Reason": "OK",
        "X-RESTfm-Method": "POST"
    },
    "metaField": [
        {
            "name": "Pcode",
            "autoEntered": 0,
            "global": 0,
            "maxRepeat": 1,
            "resultType": "text"
        },
        {
            "name": "Locality",
            "autoEntered": 0,
            "global": 0,
            "maxRepeat": 1,
            "resultType": "text"
        },
        {
            "name": "State",
            "autoEntered": 0,
            "global": 0,
            "maxRepeat": 1,
            "resultType": "text"
        },
        {
            "name": "Comments",
            "autoEntered": 0,
            "global": 0,
            "maxRepeat": 1,
            "resultType": "text"
        }
    ]
}
Example bulk JSON format CREATE response.

Changelog

Version Description
3.0.0 Added support for bulk operations.
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us