# Successful POST request | AssertionError: expected 400 to be one of \[ 200, 201 \]

**URL:** <https://community.postman.com/t/successful-post-request-assertionerror-expected-400-to-be-one-of-200-201/83527>\
**Category:** Help Hub\
**Tags:** tests, json\
**Created:** [August 13, 2025, 7:29am UTC](https://community.postman.com/t/successful-post-request-assertionerror-expected-400-to-be-one-of-200-201/83527 "2025-08-13T07:29:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![duncanyiu](https://avatars.discourse-cdn.com/v4/letter/d/dbc845/32.png) [@duncanyiu](https://community.postman.com/u/duncanyiu)\
**Post date:** [August 13, 2025, 7:29am UTC](https://community.postman.com/t/successful-post-request-assertionerror-expected-400-to-be-one-of-200-201/83527/1 "2025-08-13T07:29:46Z")

</div>

Hi All,

New to here.

I am trying to migrate some files using postman and I encounter the AssertionError.  
Please help

Many Thanks

Best Regard,

Duncan

 ![image](https://us1.discourse-cdn.com/getpostman/original/3X/9/f/9f92205145aee779224f9e5ca64eb3436e536dbe.png)

---

<div class="post-metadata">

**Author:** ![michaelderekjones](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/michaelderekjones/32/14819_2.png) [@michaelderekjones](https://community.postman.com/u/michaelderekjones)\
**Post date:** [August 13, 2025, 8:23am UTC](https://community.postman.com/t/successful-post-request-assertionerror-expected-400-to-be-one-of-200-201/83527/2 "2025-08-13T08:23:05Z")

</div>

You have a 400 error, which means the request has been crafted incorrectly.

Without knowing anything about the API or what the request needs to look like, it will be difficult to provide you any extra support here.

Do you have a link to the API documentation which tells us what the request should look like?

What I will say though is that if that migratePath is meant to be picking up files from your local drive, then it won’t work like that. Postman has very limited access to the underlying file system.
