# API: modify observation description

**URL:** <https://forum.inaturalist.org/t/api-modify-observation-description/55665>\
**Category:** General\
**Tags:** api\
**Created:** [September 18, 2024, 10:43pm UTC](https://forum.inaturalist.org/t/api-modify-observation-description/55665 "2024-09-18T22:43:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![JoeCohen](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.inaturalist.org/joecohen/32/2408_2.png) [@JoeCohen](https://forum.inaturalist.org/u/JoeCohen)\
**Post date:** [September 18, 2024, 10:43pm UTC](https://forum.inaturalist.org/t/api-modify-observation-description/55665/1 "2024-09-18T22:43:37Z")

</div>

Is it possible to modify just an observation’s `description` via the API?  
This modifies the `description` but removes the photos:

```ruby
    payload = { observation: { description: updated_description } }
    headers = { authorization: "Bearer #{@inat_import.token}",
                content_type: :json, accept: :json }

    response = RestClient.put("#{API_BASE}/observations/#{inat_obs.inat_id}",
                              payload.to_json, headers)

```

This gets a 404. (I’m guessing it’s because of the `patch`.)

```ruby
   payload = { observation: { description: updated_description } }
    headers = { authorization: "Bearer #{@inat_import.token}",
                content_type: :json, accept: :json }
    response = RestClient.patch("#{API_BASE}/observations/#{@inat_obs.inat_id}",
                                payload.to_json, headers)

```

---

<div class="post-metadata">

**Author:** ![pisum](https://avatars.discourse-cdn.com/v4/letter/p/91b2a8/32.png) [@pisum](https://forum.inaturalist.org/u/pisum)\
**Post date:** [September 18, 2024, 10:49pm UTC](https://forum.inaturalist.org/t/api-modify-observation-description/55665/2 "2024-09-18T22:49:19Z")

</div>

start here and read the rest of the thread where this quote comes from, if it doesn’t make sense:

> [@Is it possible to use the API to attach an existing photo record to an observation?](https://forum.inaturalist.org/t/is-it-possible-to-use-the-api-to-attach-an-existing-photo-record-to-an-observation/29814/5):
>
> See the note on the `ignore_photos` parameter in the [API docs](https://www.inaturalist.org/pages/api+reference#put-observations-id)

---

<div class="post-metadata">

**Author:** ![JoeCohen](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.inaturalist.org/joecohen/32/2408_2.png) [@JoeCohen](https://forum.inaturalist.org/u/JoeCohen)\
**Post date:** [September 18, 2024, 11:02pm UTC](https://forum.inaturalist.org/t/api-modify-observation-description/55665/3 "2024-09-18T23:02:09Z")

</div>

@pisum: Thanks so much for the speedy response.  
That worked perfectly.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/inaturalist/original/2X/7/7831452cf7f0d653ff1ffd34176334b7ef1b6a17.png) [@system](https://forum.inaturalist.org/u/system)\
**Post date:** [November 17, 2024, 11:02pm UTC](https://forum.inaturalist.org/t/api-modify-observation-description/55665/4 "2024-11-17T23:02:13Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
