> For the complete documentation index, see [llms.txt](https://docs.geopard.tech/geopard-tutorials/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.geopard.tech/geopard-tutorials/in/api/geopard-api-3/56..md).

# 56. फ़ोटो अपलोड करें

S3 के माध्यम से फोटो अपलोड करना 2 चरणों में होता है:

1. **प्रत्यक्ष अपलोड के लिए प्री-साइन किए गए लिंक का अनुरोध करें।**&#x20;

इनपुट के रूप में:&#x20;

* fileExtention - jpeg OR jpg OR png,&#x20;
* farmUuid - खेत का uuid,
* fieldUuid - खेत के क्षेत्र का uuid,
* noteUuid - अपलोड किए गए फोटो के प्रत्यक्ष लिंक के लिए नोट का uuid,
* commentUuid - अपलोड किए गए फोटो के प्रत्यक्ष लिंक के लिए टिप्पणी का uuid (वैकल्पिक)।&#x20;

आउटपुट के रूप में:

* uuid - अपलोड और प्रोसेसिंग के बाद अपेक्षित uuid,
* farmUuid - इनपुट के समान,
* fieldUuid - इनपुट के समान,
* noteUuid - इनपुट के समान,
* commentUuid - इनपुट के समान (यदि मौजूद हो),
* s3Url - वह URL जिसका उपयोग फोटो अपलोड करने के लिए किया जाता है,
* s3Fields - अपलोड फोटो फॉर्म में पास करने के लिए गुण।

s3Url और s3Fields का उपयोग कैसे करें, इसका विवरण दूसरे चरण में दिया गया है।&#x20;

इन गुणों की वैधता केवल 60 मिनट के लिए होती है ताकि फोटो अपलोड किया जा सके।

{% code overflow="wrap" lineNumbers="true" %}

```graphql
mutation generatePresignedPostPhotoData {
  generatePresignedPostPhotoData(input:{
    farmUuid: "89196056-61e5-4bce-b676-d488d611a829" 
    fieldUuid: "586a2ef2-03e4-4715-846c-07a2f0cb3016"
    noteUuid: "4a94da1c-f655-4f17-961a-4b0323e5129c"
    fileExtention: jpeg
    
  } ) {
    uuid
    noteUuid
    fieldUuid
    farmUuid
    s3Url
    s3Fields
  }
}
```

{% endcode %}

2. **स्थानीय फोटो को s3Fields से पूर्वनिर्धारित फॉर्म गुणों के साथ s3Url पर भेजें।**

{% code overflow="wrap" lineNumbers="true" %}

```bash
curl --location --request POST '<s3Url>' \
--form 'key="<value_in_s3Fields>"' \
--form 'AWSAccessKeyId="<value_in_s3Fields>"' \
--form 'x-amz-security-token="<value_in_s3Fields>"' \
--form 'policy="<value_in_s3Fields>"' \
--form 'signature="<value_in_s3Fields>"' \
--form 'file=@"<local_file_path>"'
```

{% endcode %}

प्रोसेसिंग के बारे में सूचनाएँ GraphQL -> Samples -> में वर्णित सब्सक्रिप्शन तंत्र के माध्यम से भेजी जाएंगी। [1. सदस्यता: घटनियाँ प्राप्त करें](/geopard-tutorials/in/api/geopard-api-3/1..md).

{% hint style="info" %}
‘Accept-Encoding’:’gzip, deflate, br’ का उपयोग करें।
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.geopard.tech/geopard-tutorials/in/api/geopard-api-3/56..md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
