1. Home
  2. Docs
  3. API Documentation
  4. Payloads
  5. UpdatePayload

UpdatePayload

Route: https://kayran.live/api/UpdatePayload

This function allows you to Edit and Update a Payload that exists on your Server.

Roles Required: Admin. Users can only Update Payloads they created.

Request Syntax

{
"apiKey": "String",
"payloadId": "String",
"name": "String",
"payload": "String",
"srcResult": "String",
"severity": int
}


Request Parameters

Parameters being used in the Request

Parameter Name :

apiKey

Parameter Usage and Options :

Your Kayran given API Key.

How do I get it ? :

Located in the “Profile” section.

Note : by default, the “API Status” is enabled, unless, the Admin has disabled it in the “Server Settings” section.

Type :

String

Is it Optional ? :

No.


Parameter Name :

payloadId

Parameter Usage and Options :

The ID of the Payload you wish to Update.

How do I get it ? :

Use GetPayloads to fetch all Payloads. Then, fetch the value of the key ‘uuid’ of the desired Payload.

Type :

String

Is it Optional ? :

No.


Parameter Name :

name

Parameter Usage and Options :

The Name of the Payload you wish to Update. For example: SQL Injection.

Type :

String

Is it Optional ? :

No.


Parameter Name :

payload

Parameter Usage and Options :

The Payload that you wish to be used.

Type :

String

Is it Optional ? :

No.


Parameter Name :

srcResult

Parameter Usage and Options :

The Result of this Payload (Regex or Text).

Type :

String

Is it Optional ? :

No.


Parameter Name :

severity

Parameter Usage and Options :

The Severity of the Payload you wish to Update.

Type :

Integer

0 – 3 (Informative-Low-Medium-High)

Is it Optional ? :

No.


Successful Response

{

    "Error": 0,

    "Function": "UpdatePayload",

    "Data": "Payload has been Successfully Updated"

}

Errors and their Possible Causes

For more information, please refer to the General Errors section.