Hi,
Per my understanding, you might want to apply site policy using JavaScript.
There seems no such method in JavaScript Client Object Model to apply site policy:
https://msdn.microsoft.com/en-us/library/office/jj193034.aspx
In Microsoft.SharePoint.Client.InformationPolicy namespace of .NET Client API, there is a ProjectPolicy object which can also be used against Office 365 SharePoint
Online environment:
https://msdn.microsoft.com/EN-US/library/office/microsoft.sharepoint.client.informationpolicy.projectpolicy_members.aspx
As a workaround, you can write code with this API to apply site policy to a site in your Office 365 tenant.
A code demo about how to work with site policy using .NET Managed Client Object Model with C# for your reference:
http://blogs.technet.com/b/tothesharepoint/archive/2013/03/28/site-policy-in-sharepoint.aspx
Thanks
Patrick Liang