Support Center
Deletes an existing link between a security definition and an SSO user.
delete_linked_auth(self, cid, ust, user_id, auth_type, auth_username, current_app, remote_addr)
cid
: Correlation ID used by audit logust
: Current user's USTuser_id
: ID of the SSO user to delete a linked account fromauth_type
: Type of the security definition that is to be unlinkedauth_username
: Username from the security definition that is to be unlinkedcurrent_app
: Name of application the call is made fromremote_addr
: Current user's remote address# -*- coding: utf-8 -*-
# Zato
from zato.server.service import Service
class DeleteLink(Service):
def handle(self):
# Request metadata
current_ust = 'gAAAAABc9YDOwa4it_lLu3tHDjdKGdjHHzLTddA_qVIxjT...'
current_app = 'CRM'
remote_addr = '127.0.0.1'
# ID of the user to create a link for
user_id = 'zusr3tm8jhgqjd9smtdt7erb427s9x'
# Account to link to the user
auth_type = 'basic_auth'
auth_username = 'pubapi'
# The link shall be active
is_active = True
# Create the link
self.sso.user.delete_linked_auth(self.cid, current_ust, user_id, auth_type,
auth_username, current_app, remote_addr)