Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 849423
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T07:06:13+00:00 2026-05-15T07:06:13+00:00

How can I POST an XML file to a local server http://localhost:8080 using cURL

  • 0

How can I POST an XML file to a local server http://localhost:8080 using cURL from the command line?

What command should I use?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T07:06:14+00:00Added an answer on May 15, 2026 at 7:06 am

    If that question is connected to your other Hudson questions use the command they provide. This way with XML from the command line:

    $ curl -X POST -d '<run>...</run>' \
    http://user:pass@myhost:myport/path/of/url
    

    You need to change it a little bit to read from a file:

     $ curl -X POST -d @myfilename http://user:pass@myhost:myport/path/of/url
    

    Read the manpage. following an abstract for -d Parameter.

    -d/–data

    (HTTP) Sends the specified data in a
    POST request to the HTTP server, in
    the same way that a browser does when
    a user has filled in an HTML form and
    presses the submit button. This will
    cause curl to pass the data to the
    server using the content-type
    application/x-www-form-urlencoded.
    Compare to -F/–form.

    -d/–data is the same as –data-ascii. To post data purely binary, you should
    instead use the –data-binary option.
    To URL-encode the value of a form
    field you may use –data-urlencode.

    If any of these options is used more
    than once on the same command line,
    the data pieces specified will be
    merged together with a separating
    &-symbol. Thus, using ‘-d name=daniel
    -d skill=lousy’ would generate a post chunk that looks like
    ‘name=daniel&skill=lousy’.

    If you start the data with the letter
    @, the rest should be a file name to
    read the data from, or – if you want
    curl to read the data from stdin. The
    contents of the file must already be
    URL-encoded. Multiple files can also
    be specified. Posting data from a file
    named ‘foobar’ would thus be done with
    –data @foobar.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a test script to receive an xml file via http post and
I'm trying to post-process the documentation XML file as a post-build XSLT transformation (using
I am creating an XML file from scratch using PHP's SimpleXML Object. But I
In My App , I POST a xml file to the server , but
When I post my events' xml file to google's server , sometimes I will
I'm using a Java program to POST some XML data from a remote client
Need to login and download xml file from the below url : http://www.radionyhetene.net/download/nyheter/mp3/nyheter.xml I
We have a website wherein a user can post information from our website to
i have not worked with XML in a while can someone post the syntax
I'm using XSLT to manipulate the data inside of an XML file (I'm taking

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.