From 940bad00e35c6c8b70be19a9dc3d24e2cc5bd8e6 Mon Sep 17 00:00:00 2001 From: Kyle Le Date: Sun, 14 Apr 2024 22:55:39 +0700 Subject: [PATCH] Issue 88 Add new Role Apis --- source/includes/_security.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/source/includes/_security.md b/source/includes/_security.md index ee7b3755..941ff43c 100644 --- a/source/includes/_security.md +++ b/source/includes/_security.md @@ -708,6 +708,11 @@ RoleDefinition roleDefinition = securityApi.getRoleDefinition(role, requestOptio ```ruby + +role = 'TestRole' + +roleDef = KillBillClient::Model::RoleDefinition.find_by_name(role, options) + ``` ```python @@ -893,6 +898,16 @@ securityApi.updateRoleDefinition(roleDefinition, requestOptions); ``` ```ruby +user = 'user' +reason = 'reason' +comment = 'comment' + +roleDef = KillBillClient::Model::RoleDefinition.new + +roleDef.role = 'TestRole' +roleDef.permissions = ["account:*", "invoice:trigger"] + +roleDef.update(user,reason,comment,options) ``` ```python