---
updatedAt: 2025-06-04T21:28:22.000Z
agentTools:
  projectIndex: https://developer.simpplr.com/llms.txt
---

# Create a Notification

Use this API to create a Notification.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "simpplr-api-gateway",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.ec.simpplr.com/api"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "oauth2",
        "flows": {}
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/notifications": {
      "post": {
        "summary": "Create a Notification",
        "description": "Use this API to create a Notification.",
        "operationId": "create-a-notification",
        "parameters": [
          {
            "name": "x-user-email",
            "in": "header",
            "description": "User's email to login into Salesforce",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "property-name",
                  "sent-to",
                  "sent-by",
                  "url",
                  "comment"
                ],
                "properties": {
                  "property-name": {
                    "type": "string",
                    "description": "How should a user be identified",
                    "default": "email",
                    "enum": [
                      "email",
                      "username"
                    ]
                  },
                  "sent-to": {
                    "type": "string",
                    "description": "If property-name is email, then the email OR if the property-name is username, then the username of the person to send this Notification to"
                  },
                  "sent-by": {
                    "type": "string",
                    "description": "If property-name is email, then the email OR if the property-name is username, then the username of the person to send this Notification to"
                  },
                  "url": {
                    "type": "string",
                    "description": "Target URL for the Notification",
                    "default": "https://test.com"
                  },
                  "notification-type": {
                    "type": "string",
                    "description": "Actionable - Notifications which require some action, like a follow request , leave approval.   Information - Notification which publishes some information",
                    "default": "Actionable",
                    "enum": [
                      "Actionable",
                      "Information"
                    ]
                  },
                  "comment": {
                    "type": "string",
                    "description": "Possible literals - {{fullName}}",
                    "default": "{{fullName}} has submitted leave request for approval"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"status\": \"success\",\n    \"result\": {\n        \"notificationId\": \"a0O5e000002ShSiEAK\"\n    },\n    \"responseTimeStamp\": \"1631691906937\",\n    \"message\": \"\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "string",
                      "example": "success"
                    },
                    "result": {
                      "type": "object",
                      "properties": {
                        "notificationId": {
                          "type": "string",
                          "example": "a0O5e000002ShSiEAK"
                        }
                      }
                    },
                    "responseTimeStamp": {
                      "type": "string",
                      "example": "1631691906937"
                    },
                    "message": {
                      "type": "string",
                      "example": ""
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "401",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"status\": \"error\",\n    \"message\": \"SESSION_TIMEOUT\",\n    \"i18nmessage\": \"SESSION_TIMEOUT\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "string",
                      "example": "error"
                    },
                    "message": {
                      "type": "string",
                      "example": "SESSION_TIMEOUT"
                    },
                    "i18nmessage": {
                      "type": "string",
                      "example": "SESSION_TIMEOUT"
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```