Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Hello Anonymous Monk,

You should be using the credentials method. Why aren't you using the credentials method?

To be honest I thought this is better passing the credentials to the header as I see the same thing happening with a CURL request. It is not the credentials that are producing the problem because on other POST / PUT / DELETE requests that I have already format are working just fine. The problem appears when I am trying to send the file.

Where does the error come from?

This error comes from the client side, complaining that it can not find the file to post it.

I dont understand what you're trying to do with that code snippet.

I am trying to post a file to server for further processing. The proposed solution that you send I will take a look, and try to apply it on my case.

Have you printed out the resulting request to see what it looks like?

Yes I am printing the return of the request and this is the error output:

$VAR1 = '{"detail":"Multipart form parse error - Invalid boundary in m +ultipart: None"}';

I will give it a try on your proposed solution and I will update my question. Thank you for your time and effort. BR / Thanos

Seeking for Perl wisdom...on the process of learning...not there...yet!

In reply to Re^2: POST file through REST::Client by thanos1983
in thread POST file through REST::Client [SOLVED] by thanos1983

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (6)
As of 2024-04-23 19:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found