For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Dashboard
User GuideDeveloper GuidesAPI Reference
User GuideDeveloper GuidesAPI Reference
    • Overview
  • Runtype API
      • POSTConfigure webhook from documentation
      • POSTInfer schema from JSON payload
      • POSTToggle webhook learning mode
      • GETGet webhook field mappings
      • PUTUpdate webhook field mappings
      • GETList webhook observations
      • DELClear webhook observations
      • GETGet event routing configuration
      • PUTUpdate event routing configuration
      • GETGet webhook schema
      • POSTUpload webhook schema
      • POSTConfirm proposed schema
Dashboard
LogoLogo
Runtype APIWebhook Management

Update webhook field mappings

PUT
/v1/products/:id/surfaces/:surfaceId/webhook-mappings
PUT
/v1/products/:id/surfaces/:surfaceId/webhook-mappings
$curl -X PUT https://api.runtype.com/v1/products/id/surfaces/surfaceId/webhook-mappings \
> -H "Authorization: <apiKey>" \
> -H "Content-Type: application/json" \
> -d '{
> "itemId": "prod_987654321",
> "mappings": [
> {
> "source": "user_email",
> "target": "emailAddress"
> },
> {
> "source": "user_signup_date",
> "target": "registrationDate"
> },
> {
> "source": "is_active",
> "target": "activeStatus"
> }
> ]
>}'
1{
2 "fieldMappings": [
3 "user_email -> emailAddress",
4 "user_signup_date -> registrationDate",
5 "is_active -> activeStatus"
6 ],
7 "id": "prod_987654321"
8}
Update field mappings for a specific surface item.
Was this page helpful?
Previous

List webhook observations

Next
Built with

Authentication

AuthorizationBearer
API key or Clerk session token

Path parameters

idstringRequired
Product ID
surfaceIdstringRequired
Surface ID

Request

This endpoint expects an object.
itemIdstringRequired
mappingslist of objectsRequired

Response

Mappings updated
fieldMappingslist of any
idstring

Errors

401
Unauthorized Error
404
Not Found Error
500
Internal Server Error