# Creating Segments

**URL:** <https://forum.mautic.org/t/creating-segments/14220>\
**Category:** Product Support\
**Created:** [May 6, 2020, 8:41pm UTC](https://forum.mautic.org/t/creating-segments/14220 "2020-05-06T20:41:05Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ritesh](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/ritesh/32/703_2.png) [@ritesh](https://forum.mautic.org/u/ritesh)\
**Post date:** [May 6, 2020, 8:41pm UTC](https://forum.mautic.org/t/creating-segments/14220/1 "2020-05-06T20:41:05Z")

</div>

**Your software**  
My Mautic version is: 2.15.3  
My PHP version is: 7.1

**Your problem**  
My problem is: I have created a role (called “SocialMediaMarketer”) that grants restricted permissions to the users and added a couple of users (say “User1” and “User2”). I was trying to create a segment using API for the User1 but getting the following response from API.

Code: 500,  
Message: Looks like I encountered an error (error #500). If I do it again, please report me to the system administrator!

This same request goes through the administrator user without any error and I can see the segment created in the system. I also noticed that there is no segment level permission(s) to select for the Role or User.

What am I missing??

These errors are showing in the log:  
Code: 500,  
Message: Looks like I encountered an error (error #500). If I do it again, please report me to the system administrator!

Steps I have tried to fix the problem:

---

<div class="post-metadata">

**Author:** ![aerendir](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/aerendir/32/1050_2.png) [@aerendir](https://forum.mautic.org/u/aerendir)\
**Post date:** [June 6, 2020, 8:20pm UTC](https://forum.mautic.org/t/creating-segments/14220/2 "2020-06-06T20:20:20Z")

</div>

You have to che k the logs in setting (gear in the upper right corner of the page) and then System info \> logs.

Paste the errors here.
