Skip to main content
PUT
/
v0
/
plugins
Update a plugin
curl --request PUT \
  --url https://controller.platform.simplecloud.app/v0/plugins \
  --header 'Content-Type: application/json' \
  --header 'X-Network-ID: <x-network-id>' \
  --header 'X-Network-Secret: <x-network-secret>' \
  --data '
{
  "name": "<string>",
  "source_type": "<string>",
  "source_value": "<string>"
}
'
import requests

url = "https://controller.platform.simplecloud.app/v0/plugins"

payload = {
"name": "<string>",
"source_type": "<string>",
"source_value": "<string>"
}
headers = {
"X-Network-ID": "<x-network-id>",
"X-Network-Secret": "<x-network-secret>",
"Content-Type": "application/json"
}

response = requests.put(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'PUT',
headers: {
'X-Network-ID': '<x-network-id>',
'X-Network-Secret': '<x-network-secret>',
'Content-Type': 'application/json'
},
body: JSON.stringify({name: '<string>', source_type: '<string>', source_value: '<string>'})
};

fetch('https://controller.platform.simplecloud.app/v0/plugins', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://controller.platform.simplecloud.app/v0/plugins",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'source_type' => '<string>',
'source_value' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Network-ID: <x-network-id>",
"X-Network-Secret: <x-network-secret>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://controller.platform.simplecloud.app/v0/plugins"

payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"source_type\": \"<string>\",\n \"source_value\": \"<string>\"\n}")

req, _ := http.NewRequest("PUT", url, payload)

req.Header.Add("X-Network-ID", "<x-network-id>")
req.Header.Add("X-Network-Secret", "<x-network-secret>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.put("https://controller.platform.simplecloud.app/v0/plugins")
.header("X-Network-ID", "<x-network-id>")
.header("X-Network-Secret", "<x-network-secret>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"source_type\": \"<string>\",\n \"source_value\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://controller.platform.simplecloud.app/v0/plugins")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)
request["X-Network-ID"] = '<x-network-id>'
request["X-Network-Secret"] = '<x-network-secret>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"source_type\": \"<string>\",\n \"source_value\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "created_at": "<string>",
  "id": "<string>",
  "mc_network_id": "<string>",
  "name": "<string>",
  "source_type": "<string>",
  "source_value": "<string>",
  "updated_at": "<string>"
}
{
"error": "<string>"
}
{
"error": "<string>"
}
{
"error": "<string>"
}
{
"error": "<string>"
}

Headers

X-Network-ID
string
required

Network ID

X-Network-Secret
string
required

Network Secret

Query Parameters

plugin_id
string
required

Plugin ID

Body

application/json

Plugin details

name
string
required
source_type
string
required
source_value
string
required

Response

OK

created_at
string
id
string
mc_network_id
string
name
string
source_type
string
source_value
string
updated_at
string