add function to check payload when calling methods