# Invalid Document Type "application/pdf"

**URL:** <https://discuss.dwolla.com/t/invalid-document-type-application-pdf/5155>\
**Category:** API Support\
**Created:** [April 17, 2019, 1:58pm UTC](https://discuss.dwolla.com/t/invalid-document-type-application-pdf/5155 "2019-04-17T13:58:27Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Stephen\_Donahue](https://sea2.discourse-cdn.com/dwolla/user_avatar/discuss.dwolla.com/stephen_donahue/32/2149_2.png) [@Stephen\_Donahue](https://discuss.dwolla.com/u/Stephen_Donahue)\
**Post date:** [April 17, 2019, 1:58pm UTC](https://discuss.dwolla.com/t/invalid-document-type-application-pdf/5155/1 "2019-04-17T13:58:27Z")

</div>

We are unable to upload any additional documents to our Dwolla Customer. Five documents have been uploaded, and we are trying to replace the ones that failed review.

We make the following request to upload the new PDF:  
`Request Params:- Method: post, Path: /customers/ad5e918d-f923-4937-8bda-735d01f00627/documents, Body: {:file=>#<UploadIO:0x00007f601cdc6468 @content_type="application/pdf", @original_filename="open-uri20190416-40-nr5y2e", @local_path="/tmp/open-uri20190416-40-nr5y2e", @io=#<File:/tmp/open-uri20190416-40-nr5y2e>, @opts={}>, :documentType=>"entity_evidence_attachment"}e[0m`

And receive the following response:  
`Response Body: {"_links"=>{"self"=>{"href"=>"https://api.dwolla.com/customers/ad5e918d-f923-4937-8bda-735d01f00627/documents", "type"=>"application/vnd.dwolla.v1.hal+json", "resource-type"=>"document"}}, "_embedded"=>{"documents"=>[{"_links"=>{"self"=>{"href"=>"https://api.dwolla.com/documents/c3ae2dcd-6985-4cd1-b55d-2525f83c8f2a", "type"=>"application/vnd.dwolla.v1.hal+json", "resource-type"=>"document"}}, "id"=>"c3ae2dcd-6985-4cd1-b55d-2525f83c8f2a", "status"=>"reviewed", "type"=>"license", "created"=>2019-04-11 16:38:19 UTC, "failureReason"=>"ScanNotReadable"}, {"_links"=>{"self"=>{"href"=>"https://api.dwolla.com/documents/d03e9944-9c8e-433a-8cb2-1ef5115ef641", "type"=>"application/vnd.dwolla.v1.hal+json", "resource-type"=>"document"}}, "id"=>"d03e9944-9c8e-433a-8cb2-1ef5115ef641", "status"=>"reviewed", "type"=>"other", "created"=>2019-04-11 17:12:25 UTC, "failureReason"=>"ScanNotReadable"}, {"_links"=>{"self"=>{"href"=>"https://api.dwolla.com/documents/dd124f02-68a5-499e-a660-fbac12dff263", "type"=>"application/vnd.dwolla.v1.hal+json", "resource-type"=>"document"}}, "id"=>"dd124f02-68a5-499e-a660-fbac12dff263", "status"=>"reviewed", "type"=>"passport", "created"=>2019-04-11 17:17:36 UTC, "failureReason"=>"ScanNotReadable"}, {"_links"=>{"self"=>{"href"=>"https://api.dwolla.com/documents/60d1cea3-c197-4806-b357-2b34373ab37e", "type"=>"application/vnd.dwolla.v1.hal+json", "resource-type"=>"document"}}, "id"=>"60d1cea3-c197-4806-b357-2b34373ab37e", "status"=>"reviewed", "type"=>"other", "created"=>2019-04-11 17:21:18 UTC, "failureReason"=>"ScanNotReadable"}, {"_links"=>{"self"=>{"href"=>"https://api.dwolla.com/documents/442d67d5-7034-42e6-972e-e3a779a0b96d", "type"=>"application/vnd.dwolla.v1.hal+json", "resource-type"=>"document"}}, "id"=>"442d67d5-7034-42e6-972e-e3a779a0b96d", "status"=>"reviewed", "type"=>"other", "created"=>2019-04-11 20:32:09 UTC}]}, "total"=>5}e[0m`

---

<div class="post-metadata">

**Author:** ![Stephen\_Donahue](https://sea2.discourse-cdn.com/dwolla/user_avatar/discuss.dwolla.com/stephen_donahue/32/2149_2.png) [@Stephen\_Donahue](https://discuss.dwolla.com/u/Stephen_Donahue)\
**Post date:** [April 17, 2019, 2:00pm UTC](https://discuss.dwolla.com/t/invalid-document-type-application-pdf/5155/2 "2019-04-17T14:00:06Z")

</div>

We’re aware of the 4-doc limit for `Pending Review` documents. But these docs have all been reviewed (and have failed, with `failureReason` returned). Cause? Workaround?

---

<div class="post-metadata">

**Author:** ![Stephen\_Donahue](https://sea2.discourse-cdn.com/dwolla/user_avatar/discuss.dwolla.com/stephen_donahue/32/2149_2.png) [@Stephen\_Donahue](https://discuss.dwolla.com/u/Stephen_Donahue)\
**Post date:** [April 17, 2019, 2:31pm UTC](https://discuss.dwolla.com/t/invalid-document-type-application-pdf/5155/3 "2019-04-17T14:31:23Z")

</div>

In addition - We’re getting a validation error due to “Invalid document type.” But the uploaded file is a PDF

`Exception: {"code"=>"ValidationError", "message"=>"Validation error(s) present. See embedded errors list for more details.", "_embedded"=>{"errors"=>[{"code"=>"Invalid", "message"=>"Invalid document type.", "path"=>"/documentType", "_links"=>{}}]}}e[0m`

From the original request:  
`@content_type="application/pdf`

---

<div class="post-metadata">

**Author:** ![shreya](https://sea2.discourse-cdn.com/dwolla/user_avatar/discuss.dwolla.com/shreya/32/2154_2.png) [@shreya](https://discuss.dwolla.com/u/shreya)\
**Post date:** [April 17, 2019, 2:41pm UTC](https://discuss.dwolla.com/t/invalid-document-type-application-pdf/5155/4 "2019-04-17T14:41:53Z")

</div>

Hi @Stephen_Donahue, the `documentType` error has to with the request body containing

> documentType=\>“entity\_evidence\_attachment”

The only acceptable values for **documentType** are `passport` , `license` , `idCard` , or `other`.  
In this scenario, you can swap out **`entity_evidence_attachment`** with **`other`**. Please let us know if that request goes through with that change!
