Invoke-WebRequest -Uri "https://discord.com/api/v6/users/@me/relationships" `
-Method "POST" `
-Headers @{
"authorization"="Token"
} `
-ContentType "application/json" `
-Body "{`"username`":`"MyUsername`",`"discriminator`":MyDiscriminator(int)}"
Это отлично работает в PowerShell
Однако в python,
import requests
print(requests.post('https://discord.com/api/v6/users/@me/relationships', headers={'authorization':'Token', 'content-type' : 'application/json'}, data={"username":"Username", "discriminator":Discriminator(Int)}))
Выдает ошибку 400.