user-imports endpoint returning 405(not allowed)

Hi everyone.
Im trying to use the jobs/users-imports to upload a json file and the endpoint is returning 405 - not allowed.
i could not find any reference to this code on the docs.

so far, I’ve tried using the Curl syntax provided on the docs ( here)

Create import users job | Auth0 Management API v2

with no joy.
here is my curl execution with the secrets removed:

curl -L ‘https://mytennt/api/v2/jobs/users-imports’ -H ‘Content-Type: multipart/form-data’ -H ‘Accept: application/json’ -H ‘Content-Type: multipart/form-data’ -F ‘upsert=“true”’ -F ‘send_completion_email=“true”’ -F ‘users=@“/tmp/users-10.json”’ -F ‘connection_id=“con_xxxxx…xxxx”’ -H ‘Authorization: Bearer ey…xxxx…’

this is the status i get back : ( extracted from curl output when using the verbose mode)

  • schannel: remote party requests renegotiation
  • schannel: renegotiating SSL/TLS connection
  • schannel: SSL/TLS connection renegotiated
  • schannel: server close notification received (close_notify)
    < HTTP/1.1 405 Method Not Allowed
    < Content-Length: 154
    < Content-Type: text/html
    < Date: Mon, 31 Mar 2025 12:23:39 GMT
    < Server: Parking/1.0
    < Connection: close
    <
405 Not Allowed

405 Not Allowed


openresty

I am sure the parameters are correct bc i am able to use the same paramaters on postman on my windows machine and it works fine.

Also, the file contents are fine. it was tested on the postman bit and uploading directly to the import users extension on the website.

and , on that note, would be very nice if the extension had tha upsert parameter.
the only reason im spending time writing a script for this is because the extension does not have the upsert parameter.

im sure this parameter would save a lot o customer work hours .

Thank you

Hi @lafayette.duarte

Could you try the following cURL command and let me know if anything changes?

curl -L 'https://{{AUTH0_DOMAIN}}/api/v2/jobs/users-imports' \
-H 'Content-Type: multipart/form-data' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {API_TOKEN}' \
-F 'connection_id="{{CONNECTION_ID}}"' \
-F 'upsert="true"' \
-F 'send_completion_email="true"' \
-F 'users=@"{{FILE_PATH}}"'

Usually, a 405 error would indicate that the HTTP method that you are trying to use is not supported by the link/endpoint or it might be a CORS issue. If the cURL provided does not work, I will come back as soon as possible with more information on the error!

Kind Regards,
Nik

Hi nik.
thank you for your response on this.
tried using your synthan and got back the same 405 - not allowed error.

Hi again,

I have been trying to reproduce the error on my end without any success.

We were experiencing some issues with the Management API page yesterday which have been fixed at this time.

Could you please visit the Create a User Import Job page and attempt attempt to:

  1. Submit the import job from the page
  2. Insert the body parameters → Copy the cURL command → replace the patch name with the correct one → attempt to run the command in your terminal window

Could you let me know what happens in both these scenarios?

Kind Regards,
Nik