> For the complete documentation index, see [llms.txt](https://docs.obto.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.obto.co/applications/client-policies.md).

# Client Policies

## How to create a Client Policy

A client policy is the controller for the UI Template. It controls what data is to be shown on UI Template by applying logics.&#x20;

In order to create a Client Policy, follow these steps: -&#x20;

1. On navigation, under Policies, go to Client Policies. You will see a list of all the Client Policies belonging to different applications.&#x20;
2. Click on ‘settings icon’ on top left corner and then click ‘new’.&#x20;
3. A form appears where you have to provide the following details: -&#x20;
4. Name - name of the Client Policy.&#x20;
5. Type: -&#x20;
6. Execute onload – client policy executes when the application loads.&#x20;
7. Execute on change – client policy executes when some form input changes in the                application.&#x20;
8. Script – The JavaScript code (Controller).&#x20;
9. Run On – client policies are meant for platform applications and applications outside the             platform.&#x20;
10. Native – Execute the client policy for the platform applications.&#x20;
11. Portal – Execute the client policy for outside applications.&#x20;
12. Click on ‘create’ button. That’s it, you have created the Client Policy for the application.&#x20;
