Title: Create level API
Last modified: March 1, 2019

---

# Create level API

 *  Resolved [annakolozsvari](https://wordpress.org/support/users/annakolozsvari/)
 * (@annakolozsvari)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/create-level-api/)
 * Hello,
    I’m trying to add a ‘New Access Level’ button on the frontend. Is there
   an API I can call to create a new access level? I found the get function, but
   I’d also like to be able to create and update levels. Thanks for your time! Anna

Viewing 1 replies (of 1 total)

 *  Plugin Author [Joachim Jensen](https://wordpress.org/support/users/intoxstudio/)
 * (@intoxstudio)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/create-level-api/#post-11465450)
 * Apologies for the delayed response here.
 * Unfortunately there is no way to create levels programmatically yet, but it is
   on the roadmap. Since levels are stored as a custom post type `restriction`, 
   you can look into:
 * [https://developer.wordpress.org/reference/functions/wp_insert_post/](https://developer.wordpress.org/reference/functions/wp_insert_post/)
 * Though it will not contain the various settings and conditions if doing it this
   way.

Viewing 1 replies (of 1 total)

The topic ‘Create level API’ is closed to new replies.

 * ![](https://ps.w.org/restrict-user-access/assets/icon-256x256.png?rev=1815922)
 * [Restrict User Access - Ultimate Membership & Content Protection](https://wordpress.org/plugins/restrict-user-access/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/restrict-user-access/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/restrict-user-access/)
 * [Active Topics](https://wordpress.org/support/plugin/restrict-user-access/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/restrict-user-access/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/restrict-user-access/reviews/)

## Tags

 * [api](https://wordpress.org/support/topic-tag/api/)
 * [code](https://wordpress.org/support/topic-tag/code/)
 * [program](https://wordpress.org/support/topic-tag/program/)

 * 1 reply
 * 2 participants
 * Last reply from: [Joachim Jensen](https://wordpress.org/support/users/intoxstudio/)
 * Last activity: [6 years, 11 months ago](https://wordpress.org/support/topic/create-level-api/#post-11465450)
 * Status: resolved