curl --request POST \
--url https://developers.myfundedperpetuals.com/v1/trader-lockout \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"acknowledged": true,
"account_ids": [
"<string>"
],
"all_accounts": true,
"expires_at": 123,
"close_trades_first": false
}
'import requests
url = "https://developers.myfundedperpetuals.com/v1/trader-lockout"
payload = {
"acknowledged": True,
"account_ids": ["<string>"],
"all_accounts": True,
"expires_at": 123,
"close_trades_first": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
acknowledged: true,
account_ids: ['<string>'],
all_accounts: true,
expires_at: 123,
close_trades_first: false
})
};
fetch('https://developers.myfundedperpetuals.com/v1/trader-lockout', 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://developers.myfundedperpetuals.com/v1/trader-lockout",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'acknowledged' => true,
'account_ids' => [
'<string>'
],
'all_accounts' => true,
'expires_at' => 123,
'close_trades_first' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://developers.myfundedperpetuals.com/v1/trader-lockout"
payload := strings.NewReader("{\n \"acknowledged\": true,\n \"account_ids\": [\n \"<string>\"\n ],\n \"all_accounts\": true,\n \"expires_at\": 123,\n \"close_trades_first\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.post("https://developers.myfundedperpetuals.com/v1/trader-lockout")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"acknowledged\": true,\n \"account_ids\": [\n \"<string>\"\n ],\n \"all_accounts\": true,\n \"expires_at\": 123,\n \"close_trades_first\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://developers.myfundedperpetuals.com/v1/trader-lockout")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"acknowledged\": true,\n \"account_ids\": [\n \"<string>\"\n ],\n \"all_accounts\": true,\n \"expires_at\": 123,\n \"close_trades_first\": false\n}"
response = http.request(request)
puts response.read_body{
"data": {
"status": "locked",
"expires_at": 123,
"accounts": [
{
"account_id": "<string>",
"name": "<string>",
"trader_lockout": {
"id": "<string>",
"started_at": 123,
"expires_at": 123
}
}
],
"closed_positions": 123,
"canceled_orders": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {}
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {}
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}Start or extend a trader lockout
Irreversible. Locks trading on the named accounts, or on every active account this key can see (all_accounts), until the chosen time. It cannot be ended or shortened early, by you or by Support, so acknowledged: true is required. Choose the unlock time with a duration preset (as on the website: 15 minutes to 24 hours, or the next midnight New York time) or an exact future expires_at, at most 90 days away. A request may extend an account’s running lockout, never shorten it: an unlock time earlier than a running lockout is refused with 409 trader_lockout_ends_later. Open positions, resting orders, exit orders, and running TWAP and scaled orders stay as they are unless close_trades_first is true. Then every open trade on up to 100 accounts is canceled or closed with reduce-only market orders first, and the accounts lock only once all of them are flat; otherwise nothing locks and the response says what was closed. Closing gets about 70 seconds; trades still open after that are reported the same way, with nothing locked. Requires trade scope. Starting lockouts is rate limited per user: 5 at once, refilling at 10 an hour, and refused requests count too. Close-and-lock is limited further, per user to a burst of one, refilling at 4 an hour, and can return 429 when many are running across the platform. A key revoked or narrowed while a request runs stops it before the next close or the lock. The reported counts and pending_work cover only the closes and cancels this request submitted itself. When a selected account leads copy trading, copies of its closes on follower accounts run separately and are not counted, even on a selected follower; a selected follower still locks only once it is flat.
curl --request POST \
--url https://developers.myfundedperpetuals.com/v1/trader-lockout \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"acknowledged": true,
"account_ids": [
"<string>"
],
"all_accounts": true,
"expires_at": 123,
"close_trades_first": false
}
'import requests
url = "https://developers.myfundedperpetuals.com/v1/trader-lockout"
payload = {
"acknowledged": True,
"account_ids": ["<string>"],
"all_accounts": True,
"expires_at": 123,
"close_trades_first": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
acknowledged: true,
account_ids: ['<string>'],
all_accounts: true,
expires_at: 123,
close_trades_first: false
})
};
fetch('https://developers.myfundedperpetuals.com/v1/trader-lockout', 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://developers.myfundedperpetuals.com/v1/trader-lockout",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'acknowledged' => true,
'account_ids' => [
'<string>'
],
'all_accounts' => true,
'expires_at' => 123,
'close_trades_first' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://developers.myfundedperpetuals.com/v1/trader-lockout"
payload := strings.NewReader("{\n \"acknowledged\": true,\n \"account_ids\": [\n \"<string>\"\n ],\n \"all_accounts\": true,\n \"expires_at\": 123,\n \"close_trades_first\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.post("https://developers.myfundedperpetuals.com/v1/trader-lockout")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"acknowledged\": true,\n \"account_ids\": [\n \"<string>\"\n ],\n \"all_accounts\": true,\n \"expires_at\": 123,\n \"close_trades_first\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://developers.myfundedperpetuals.com/v1/trader-lockout")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"acknowledged\": true,\n \"account_ids\": [\n \"<string>\"\n ],\n \"all_accounts\": true,\n \"expires_at\": 123,\n \"close_trades_first\": false\n}"
response = http.request(request)
puts response.read_body{
"data": {
"status": "locked",
"expires_at": 123,
"accounts": [
{
"account_id": "<string>",
"name": "<string>",
"trader_lockout": {
"id": "<string>",
"started_at": 123,
"expires_at": 123
}
}
],
"closed_positions": 123,
"canceled_orders": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {}
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {}
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": [
{
"field": "<string>",
"issue": "<string>"
}
]
}
}Authorizations
API key beginning with fp_live_ (live keys, served at developers.myfundedperpetuals.com) or fp_test_ (test keys, served at sandbox.myfundedperpetuals.com). A key presented on the other host is rejected with 401 and a message naming the correct host. Affiliate API keys are fp_live_ keys created on the Affiliates page: they read only the /v1/affiliate endpoints and get 403 with code insufficient_scope on every other authenticated endpoint. Every other key gets the same 403 on /v1/affiliate.
Body
Send exactly one of account_ids and all_accounts, and exactly one of duration and expires_at.