# \_list

Returns the IDs and creation dates of all non-archived versions of an object which can have changes undone.\
(Currently only on Forms)

### Parameters

#### obj\_id

The ID of the object, available versions of this object will be retrieved.

#### obj\_type

The type of object which this function is retrieving versions from:

* forms

#### fields

An array of additional fields about the versions which can be returned:

* name
* data
* obj\_id
* obj\_type

### Example

```
FM_api('Undos_list',[
    'obj_id'=>'580335',
    'obj_type'=>'forms',
    'fields'=>'["name","data"]'
    ]
);
```

### Result

#### On Success

Without the "fields" parameter:

```
[{"id":"90001","cdate":"1722329099"},{"id":"90002","cdate":"1722329115"}]
```

With the "fields" parameter, including the names and data:

```
[{"id":"90001","cdate":"1722329099","name":"the original","data":"{\"archived\": \"0\", \"autodocs\": \"[]\", \"autodocs_doc\": \"{\\\"header\\\":\\\"\\\",\\\"body\\\":\\\"\\\",\\\"footer\\\":\\\"\\\"}\", \"cdate\": \"2024-07-30 08:44:58\", \"department_id\": \"0\", \"email_template_id\": \"0\", \"fields\": \"[{\\\"name\\\":\\\"unddddddddddddo\\\",\\\"type\\\":\\\"input\\\",\\\"meta\\\":\\\"{\\\\\\\"id\\\\\\\":1814466045813}\\\"}]\", \"id\": \"580335\", \"is_invoiceable\": \"1\", \"last_edited\": \"2024-07-30 08:44:59\", \"meta\": \"{\\\"theme\\\":\\\"\\\",\\\"disable-pdf-conversion\\\":0,\\\"disable-doc-export\\\":0,\\\"send_notification\\\":0,\\\"do_not_update_stock_levels\\\":0,\\\"slots\\\":\\\"{}\\\",\\\"required_skills\\\":[]}\", \"name\": \"Name of Form Undo Test\", \"on_complete\": \"[]\", \"owner_id\": \"0\", \"phpdocx_version\": \"-1\", \"portal_visibility\": \"1\", \"preferred_type\": \"0\", \"replyto\": \"no-reply@fieldmotion.com\", \"report_type\": \"1\", \"select_by_default\": \"0\", \"template\": \"\", \"type\": \"0\", \"uses_stock\": \"1\"}"},{"id":"90002","cdate":"1722329115","name":null,"data":"{\"archived\": \"0\", \"autodocs\": \"[]\", \"autodocs_doc\": \"{\\\"header\\\":\\\"\\\",\\\"body\\\":\\\"\\\",\\\"footer\\\":\\\"\\\"}\", \"cdate\": \"2024-07-30 08:44:58\", \"department_id\": \"0\", \"email_template_id\": \"0\", \"fields\": \"[{\\\"name\\\":\\\"unddddddddddddo\\\",\\\"type\\\":\\\"input\\\",\\\"sources\\\":\\\"[]\\\",\\\"visibility_rules\\\":\\\"[]\\\",\\\"meta\\\":\\\"{\\\\\\\"id\\\\\\\":1814466045813}\\\"},{\\\"name\\\":\\\"exist\\\",\\\"type\\\":\\\"input\\\",\\\"meta\\\":\\\"{\\\\\\\"id\\\\\\\":1739192279186}\\\"}]\", \"id\": \"580335\", \"is_invoiceable\": \"1\", \"last_edited\": \"2024-07-30 08:45:15\", \"meta\": \"{\\\"theme\\\":\\\"\\\",\\\"disable-pdf-conversion\\\":0,\\\"disable-doc-export\\\":0,\\\"send_notification\\\":0,\\\"do_not_update_stock_levels\\\":0,\\\"slots\\\":\\\"{}\\\",\\\"required_skills\\\":[]}\", \"name\": \"Name of Form Undo Test\", \"on_complete\": \"[]\", \"owner_id\": \"0\", \"phpdocx_version\": \"-1\", \"portal_visibility\": \"1\", \"preferred_type\": \"0\", \"replyto\": \"no-reply@fieldmotion.com\", \"report_type\": \"1\", \"select_by_default\": \"0\", \"template\": \"\", \"type\": \"0\", \"uses_stock\": \"1\"}"}]
```


---

# Agent Instructions: 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.fieldmotion.com/fieldmotion-api-docs/undos/_list.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.
