Retrieves a policy by ID.
The getPolicy()
function returns a Promise that resolves to a policy whose ID matches the given ID.
function getPolicy(policyId: string): Promise<Policy>;
Policy ID.
import { policies } from "@wix/events";
async function getPolicy(policyId) {
const response = await policies.getPolicy(policyId);
}
This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.