# Role not found - 404

**URL:** <https://community.dreamfactory.com/t/role-not-found-404/3282>\
**Category:** Users & Roles\
**Created:** [October 2, 2016, 7:07am UTC](https://community.dreamfactory.com/t/role-not-found-404/3282 "2016-10-02T07:07:10Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![smilesinblues](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@smilesinblues](https://community.dreamfactory.com/u/smilesinblues)\
**Post date:** [October 2, 2016, 7:07am UTC](https://community.dreamfactory.com/t/role-not-found-404/3282/1 "2016-10-02T07:07:10Z")

</div>

Hi,

Ive tried everything that I could think of, but I am still getting this message when I call the email service via POST.

I setup an AWS SES email service, then Assigned Service Access to that Role. I have also assigned the role to the app.

Now when I use the API\_DOCS the email is working fine, but when I use the POST method via POSTMAN etc it shows role not found. I have tried almost everything that I could think of, please help.

Thanks,

---

<div class="post-metadata">

**Author:** ![DFCommunityManager](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/dfcommunitymanager/32/887_2.png) [@DFCommunityManager](https://community.dreamfactory.com/u/DFCommunityManager)\
**Post date:** [October 3, 2016, 3:13pm UTC](https://community.dreamfactory.com/t/role-not-found-404/3282/2 "2016-10-03T15:13:30Z")

</div>

Can you send me a screen shot of the role privileges? Please confirm you have allowed for POST. Go to Roles - Access.

![](https://canada1.discourse-cdn.com/flex035/uploads/dreamfactory/original/1X/05859977a6a40a9a8dd8b9a180904624adcc74d5.png)

[A “Role not found” Error](https://wiki.dreamfactory.com/DreamFactory/Troubleshooting) means that a role may not be assigned to you for your app.

- A role could not be determined in order to allow access to the api call.
- If the call was made with an api key and a session token, then the user does not have a role assigned for this api key, and the api key has no default role.
- If the call was make with an api key only, then the api key has no default role.
- Assign the appropriate role in the admin console.

Your error indicates that no role was found. If you have not assigned a default role to your app (associated with your API key) then you will receive this error. If you are providing authentication with a session token, and the authenticated user doesn’t have a role associated with that app (API key) then you will receive this error.

All calls in DreamFactory require an API key. They also require a role that permits access to the resource specified in the call. The role is determined by the user’s user to app to role relationship, if the call included session information, or by checking the default role for the app, if no session info is provided.

A few exceptions:

- User login and User registration calls do not require a role or API key.
- Admin sessions do not require an API key. When you use API Docs in the admin console, the system passes the admin session in the background for you.

See wiki documentation here: [https://wiki.dreamfactory.com/DreamFactory/API](https://wiki.dreamfactory.com/DreamFactory/API)

Thanks,  
@AlexBowen

---

<div class="post-metadata">

**Author:** ![smilesinblues](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@smilesinblues](https://community.dreamfactory.com/u/smilesinblues)\
**Post date:** [October 6, 2016, 5:21pm UTC](https://community.dreamfactory.com/t/role-not-found-404/3282/3 "2016-10-06T17:21:35Z")

</div>

Hi,

After trying and retrying I got frustrated. Deleted the whole thing and started from scratch, and it worked 😄

Thank you for replying, I think we can close this.

Thanks

---

<div class="post-metadata">

**Author:** ![DFCommunityManager](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/dfcommunitymanager/32/887_2.png) [@DFCommunityManager](https://community.dreamfactory.com/u/DFCommunityManager)\
**Post date:** [October 7, 2016, 8:30pm UTC](https://community.dreamfactory.com/t/role-not-found-404/3282/4 "2016-10-07T20:30:56Z")

</div>

Sorry to hear you got frustrated, but I’m glad you stuck to it and were able to get it working!

Keep us updated with what you’re working on @smilesinblues. 🙂

Thanks,  
@AlexBowen

---

<div class="post-metadata">

**Author:** ![regalartech](https://avatars.discourse-cdn.com/v4/letter/r/2bfe46/32.png) [@regalartech](https://community.dreamfactory.com/u/regalartech)\
**Post date:** [March 29, 2019, 8:27am UTC](https://community.dreamfactory.com/t/role-not-found-404/3282/5 "2019-03-29T08:27:34Z")

</div>

but the root problem still exist right ? deleting and starting from scratch is the real solution ?

What is real / permanent l solution for this.

---

<div class="post-metadata">

**Author:** ![regalartech](https://avatars.discourse-cdn.com/v4/letter/r/2bfe46/32.png) [@regalartech](https://community.dreamfactory.com/u/regalartech)\
**Post date:** [March 29, 2019, 9:29am UTC](https://community.dreamfactory.com/t/role-not-found-404/3282/6 "2019-03-29T09:29:59Z")

</div>

I found out !!! my service name was not matching . but as the error was about the role I was searching in the role , app , user … but actual problem was from mismatch of custom script service name that’s it.

Suggested improvement to the Dreamfactory team : just put a check if service name matches or not.
