Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

413 Request Entity Too Large

Rafael July 26, 2018

https://page/rest/api/latest/issue/{{issue.id}}/attachments

Hello, I try send attach to issue. file size 1.2mb and I get this message.

<html>
<head>
<title>413 Request Entity Too Large</title>
</head>
<body bgcolor="white">
<center>
<h1>413 Request Entity Too Large</h1>
</center>
<hr>
<center>nginx/1.12.2</center>
</body>
</html>

Try send by curl php  

$ch=curl_init();
$headers = array(
'X-Atlassian-Token: nocheck',
'Content-Type: multipart/form-data'
);

$cfile
= new \CURLFile('/home/media/1.jpg');
$cfile->setPostFilename('_2018-06-29_12-55-15_4.jpg');
$cfile->setMimeType('image/jpg');
$data = array('file'=>$cfile);
curl_setopt_array(
$ch,
array(
CURLOPT_URL=>$attachUrl,
CURLOPT_POST=>true,
CURLOPT_VERBOSE=>1,
CURLOPT_POSTFIELDS=>$data,
CURLOPT_INFILESIZE => 5,
CURLOPT_SSL_VERIFYHOST=> 0,
CURLOPT_SSL_VERIFYPEER=> 0,
CURLOPT_RETURNTRANSFER=>true,
CURLOPT_HEADER=>true,
CURLOPT_HTTPHEADER=> $headers,
CURLOPT_USERPWD=>"$JiraUsername:$JiraPassword"
)
);
$result=curl_exec($ch);
$ch_error = curl_error($ch);

 

1 comment

Timothy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 26, 2018

This is an error from your nginx proxy, not a Jira problem.

Comment

Log in or Sign up to comment
TAGS
AUG Leaders

Atlassian Community Events