sgerodes / 3commas-postman

A postman collection for the 3 commas API. The Signature is calculated automatically.
MIT License
8 stars 9 forks source link

Trouble with Smart Trades #2

Open theDanielJLewis opened 2 years ago

theDanielJLewis commented 2 years ago

Thank you for putting this together!

I'm having trouble creating Smart Trades in a paper account. I know I have my API and secret properly entered because I can get an account list from both paper and real.

When I try to create a Smart Trade, I get the error:

{
    "error": "signature_invalid",
    "error_description": "Provided signature is invalid"
}

If I send only account_id and pair, then I get:

{
    "error": "record_invalid",
    "error_description": "Invalid parameters",
    "error_attributes": {
        "position": [
            "is missing"
        ],
        "position[type]": [
            "is missing"
        ],
        "position[order_type]": [
            "is missing"
        ],
        "position[units]": [
            "is missing"
        ],
        "position[units][value]": [
            "is missing"
        ],
        "take_profit": [
            "is missing"
        ],
        "take_profit[enabled]": [
            "is missing"
        ],
        "stop_loss": [
            "is missing"
        ],
        "stop_loss[enabled]": [
            "is missing"
        ]
    }
}

But add any one of those fields and I get the signature error.

Any ideas? Or is this a 3commas problem?

sgerodes commented 2 years ago

Do you have any spaces in your url? if yes, that could be the issue

theDanielJLewis commented 2 years ago

No.

It seems to be a problem with how the authentication script is handling an object or array.

sgerodes commented 2 years ago

Tbh, I think the problem is somewhere on the side of 3commas. I cant send a Smart trade too. Because the auth script does not change your object. It does not delete any fields.

lotek4u commented 1 year ago

Were you guys able to eventually create smart trades, or still borked on their side?

theDanielJLewis commented 1 year ago

I gave up and used a different method to send the data.