Match Targets

class Match_Targets(session_kwargs, client, return_type='raw')

Methods

delete_shares_groups(id, group_id)

Revoke the permissions a group has on this object

delete_shares_users(id, user_id)

Revoke the permissions a user has on this object

get(id)

Show Match Target info

list()

List match targets

list_shares(id)

List users and groups permissioned on this object

patch(id, *[, name, target_file_name, archived])

Update a match target

post(name, *[, target_file_name, archived])

Create a new match target

put_archive(id, status)

Update the archive status of this object

put_shares_groups(id, group_ids, ...[, ...])

Set the permissions groups has on this object

put_shares_users(id, user_ids, ...[, ...])

Set the permissions users have on this object

Examples

>>> import civis
>>> client = civis.APIClient()
>>> client.match_targets.list_shares(...)
delete_shares_groups(id: int, group_id: int) Response

Revoke the permissions a group has on this object

Parameters:
idint

The ID of the resource that is shared.

group_idint

The ID of the group.

Returns:
None

Response code 204: success

delete_shares_users(id: int, user_id: int) Response

Revoke the permissions a user has on this object

Parameters:
idint

The ID of the resource that is shared.

user_idint

The ID of the user.

Returns:
None

Response code 204: success

get(id: int) Response

Show Match Target info

Parameters:
idint

The ID of the match target

Returns:
civis.Response
  • idint

    The ID of the match target

  • namestr

    The name of the match target

  • target_file_namestr

    The name of the target file

  • created_at : str (time)

  • updated_at : str (time)

  • archivedbool

    Whether the match target has been archived.

list() Response

List match targets

Returns:
civis.Response
  • idint

    The ID of the match target

  • namestr

    The name of the match target

  • target_file_namestr

    The name of the target file

  • created_at : str (time)

  • updated_at : str (time)

  • archivedbool

    Whether the match target has been archived.

list_shares(id: int) Response

List users and groups permissioned on this object

Parameters:
idint

The ID of the resource that is shared.

Returns:
civis.Response
patch(id: int, *, name: str = None, target_file_name: str = None, archived: bool = None) Response

Update a match target

Parameters:
idint

The ID of the match target

namestr, optional

The name of the match target

target_file_namestr, optional

The name of the target file

archivedbool, optional

Whether the match target has been archived.

Returns:
civis.Response
  • idint

    The ID of the match target

  • namestr

    The name of the match target

  • target_file_namestr

    The name of the target file

  • created_at : str (time)

  • updated_at : str (time)

  • archivedbool

    Whether the match target has been archived.

post(name: str, *, target_file_name: str = None, archived: bool = None) Response

Create a new match target

Parameters:
namestr

The name of the match target

target_file_namestr, optional

The name of the target file

archivedbool, optional

Whether the match target has been archived.

Returns:
civis.Response
  • idint

    The ID of the match target

  • namestr

    The name of the match target

  • target_file_namestr

    The name of the target file

  • created_at : str (time)

  • updated_at : str (time)

  • archivedbool

    Whether the match target has been archived.

put_archive(id: int, status: bool) Response

Update the archive status of this object

Parameters:
idint

The ID of the object.

statusbool

The desired archived status of the object.

Returns:
civis.Response
  • idint

    The ID of the match target

  • namestr

    The name of the match target

  • target_file_namestr

    The name of the target file

  • created_at : str (time)

  • updated_at : str (time)

  • archivedbool

    Whether the match target has been archived.

put_shares_groups(id: int, group_ids: List[int], permission_level: str, *, share_email_body: str = None, send_shared_email: bool = None) Response

Set the permissions groups has on this object

Parameters:
idint

The ID of the resource that is shared.

group_idsList[int]

An array of one or more group IDs.

permission_levelstr

Options are: “read”, “write”, or “manage”.

share_email_bodystr, optional

Custom body text for e-mail sent on a share.

send_shared_emailbool, optional

Send email to the recipients of a share.

Returns:
civis.Response
put_shares_users(id: int, user_ids: List[int], permission_level: str, *, share_email_body: str = None, send_shared_email: bool = None) Response

Set the permissions users have on this object

Parameters:
idint

The ID of the resource that is shared.

user_idsList[int]

An array of one or more user IDs.

permission_levelstr

Options are: “read”, “write”, or “manage”.

share_email_bodystr, optional

Custom body text for e-mail sent on a share.

send_shared_emailbool, optional

Send email to the recipients of a share.

Returns:
civis.Response