Progress will discontinue Telerik Platform on May 10th, 2018. Learn more

Reading Stored Procedure Mappings

Reading Stored Procedure Mappings

You can read metadata about endpoints that have stored procedures mapped to them. The operation gives you information about the name of the endpoint, the stored procedure parameters, default values, and so on.

These are the RESTful operations that you can use to retrieve metadata about HTTP endpoints to which you mapped stored procedures:

Read All

Use this operation to read information about all mapped stored procedures or functions. You can find more information about the return fields in Mapped Stored Procedure Object Fields.

Request:
    GET https://api.everlive.com/v1/Metadata/Applications/your-app-id/Procedures
Headers:
    Content-Type: application/json
    Authorization: Masterkey your-master-key-here
Response:
    Status: 200 OK
    Content-Type: application/json
Payload - raw:
    {
        "Count": 2,
        "Result": [{
            "Name": "generateRandomString",
            "CreatedAt": "2015-06-23T11:04:23.806Z",
            "ModifiedAt": "2015-06-23T11:40:18.415Z",
            "DataLinkId": "d8e9fbf0-1996-11e5-ac3d-4796c3b1ba9d",
            "ProcedureCatalog": "telerik",
            "ProcedureSchema": "dbo",
            "ProcedureName": "GenerateRandomString",
            "Mapping": [{
                "Name": "@sLength",
                "Type": 1,
                "Position": 1,
                "DataType": -6,
                "DefaultValue": null,
                "Validators": {
                    "Required": true
                },
                "EverliveType": "Number",
                "ServerName": "@sLength"
            }, {
                "Name": "@randomString",
                "Type": 2,
                "Position": 2,
                "DataType": 12,
                "DefaultValue": null,
                "Validators": {
                    "Required": true
                },
                "EverliveType": "Text",
                "ServerName": "@randomString"
            }],
            "ModifiedBy": "00000000-0000-0000-0000-000000000000",
            "Id": "9b2111e0-1997-11e5-aa5e-854c716bee06"
        }, {
            "Name": "InsertTax",
            "CreatedAt": "2015-06-23T11:42:20.776Z",
            "ModifiedAt": "2015-06-23T14:03:41.926Z",
            "DataLinkId": "d8e9fbf0-1996-11e5-ac3d-4796c3b1ba9d",
            "ProcedureCatalog": "telerik",
            "ProcedureSchema": "dbo",
            "ProcedureName": "CalculatedTax_Insert",
            "Mapping": [{
                "Name": "@OrderPrice",
                "Type": 1,
                "Position": 1,
                "DataType": 3,
                "DefaultValue": null,
                "Validators": {
                    "Required": true
                },
                "EverliveType": "Number",
                "ServerName": "@OrderPrice"
            }, {
                "Name": "@State",
                "Type": 1,
                "Position": 5,
                "DataType": 12,
                "DefaultValue": null,
                "Validators": {
                    "Required": true
                },
                "EverliveType": "Text",
                "ServerName": "@State"
            }, {
                "Name": "@TaxAmount",
                "Type": 1,
                "Position": 7,
                "DataType": 3,
                "DefaultValue": null,
                "Validators": {
                    "Required": true
                },
                "EverliveType": "Number",
                "ServerName": "@StateTaxAmount"
            }],
            "ModifiedBy": "00000000-0000-0000-0000-000000000000",
            "Id": "e84f1e80-199c-11e5-9f0d-4ba7449cc0d5"
        }]
    }

Read by ID

Use this operation to read a single mapped stored procedure or function by its ID.

Request:
    GET https://api.everlive.com/v1/Metadata/Applications/your-app-id/Procedures/mapped-procedure-id-here
Headers:
    Content-Type: application/json
    Authorization: Masterkey your-master-key-here
Response:
    Status: 200 OK
    Content-Type: application/json
Payload - raw:
{
    "Result": {
        "Name": "generateRandomString",
        "CreatedAt": "2015-06-23T11:04:23.806Z",
        "ModifiedAt": "2015-06-23T11:40:18.415Z",
        "DataLinkId": "d8e9fbf0-1996-11e5-ac3d-4796c3b1ba9d",
        "ProcedureCatalog": "telerik",
        "ProcedureSchema": "dbo",
        "ProcedureName": "GenerateRandomString",
        "Mapping": [{
            "Name": "@sLength",
            "Type": 1,
            "Position": 1,
            "DataType": -6,
            "DefaultValue": null,
            "Validators": {
                "Required": true
            },
            "EverliveType": "Number",
            "ServerName": "@sLength"
        }, {
            "Name": "@randomString",
            "Type": 2,
            "Position": 2,
            "DataType": 12,
            "DefaultValue": null,
            "Validators": {
                "Required": true
            },
            "EverliveType": "Text",
            "ServerName": "@randomString"
        }],
        "ModifiedBy": "00000000-0000-0000-0000-000000000000",
        "Id": "9b2111e0-1997-11e5-aa5e-854c716bee06"
    }
}

Read by Filter

Use this operation to return a subset of mapped stored procedures or functions that match the specified filtering criteria.

The example below only matches objects where Name is equal to generateRandomString:

Request:
    GET https://api.everlive.com/v1/Metadata/Applications/your-app-id/Procedures
Headers:
    Content-Type: application/json
    Authorization: Masterkey your-master-key-here
    X-Everlive-Filter: {"Name": "generateRandomString"}
Response:
    Status: 200 OK
    Content-Type: application/json
Payload - raw:
{
    "Count": 1,
    "Result": [{
        "Name": "generateRandomString",
        "CreatedAt": "2015-06-23T11:04:23.806Z",
        "ModifiedAt": "2015-06-23T11:40:18.415Z",
        "DataLinkId": "d8e9fbf0-1996-11e5-ac3d-4796c3b1ba9d",
        "ProcedureCatalog": "telerik",
        "ProcedureSchema": "dbo",
        "ProcedureName": "GenerateRandomString",
        "Mapping": [{
            "Name": "@sLength",
            "Type": 1,
            "Position": 1,
            "DataType": -6,
            "DefaultValue": null,
            "Validators": {
                "Required": true
            },
            "EverliveType": "Number",
            "ServerName": "@sLength"
        }, {
            "Name": "@randomString",
            "Type": 2,
            "Position": 2,
            "DataType": 12,
            "DefaultValue": null,
            "Validators": {
                "Required": true
            },
            "EverliveType": "Text",
            "ServerName": "@randomString"
        }],
        "ModifiedBy": "00000000-0000-0000-0000-000000000000",
        "Id": "9b2111e0-1997-11e5-aa5e-854c716bee06"
    }]
}

See Also

Start a free trial Request a demo
Contact us: +1-888-365-2779
sales@telerik.com
Copyright © 2016-2017, Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved.