httr (version 0.3)

upload_file: Upload a file with POST or PUT.

Description

This is a tiny wrapper for RCurl's fileUpload.

Usage

upload_file(path)

Arguments

path
path to file

Examples

Run this code
POST("http://httpbin.org/post",
  body = list(y = upload_file(system.file("CITATION"))))

Run the code above in your browser using DataCamp Workspace