effectivelywild.technitium_dns.technitium_dns_get_user_details module – Get user account profile details from Technitium DNS server

Note

This module is part of the effectivelywild.technitium_dns collection (version 0.4.0).

It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install effectivelywild.technitium_dns.

To use it in a playbook, specify: effectivelywild.technitium_dns.technitium_dns_get_user_details.

New in effectivelywild.technitium_dns 0.4.0

Synopsis

  • Retrieve detailed information about a user account from Technitium DNS server.

  • Returns user profile, session information, and group memberships.

  • Groups information is always included in the response.

Parameters

Parameter

Comments

api_port

integer

Port for the Technitium DNS API. Defaults to 5380

Default: 5380

api_token

string / required

API token for authenticating with the Technitium DNS API

api_url

string / required

Base URL for the Technitium DNS API

username

string / required

The username for the user account to get details for

validate_certs

boolean

Whether to validate SSL certificates when making API requests

Choices:

  • false

  • true ← (default)

See Also

See also

effectivelywild.technitium_dns.technitium_dns_create_user

Create a user account in Technitium DNS server

effectivelywild.technitium_dns.technitium_dns_delete_user

Delete a user from Technitium DNS server

effectivelywild.technitium_dns.technitium_dns_list_users

List all users from Technitium DNS server

effectivelywild.technitium_dns.technitium_dns_set_user_details

Set user account details on Technitium DNS server

Examples

- name: Get admin user details
  technitium_dns_get_user_details:
    api_url: "http://localhost"
    api_token: "myapitoken"
    username: "admin"
  register: result

- debug:
    var: result.user_details

- name: Get user details for a specific user
  technitium_dns_get_user_details:
    api_url: "http://localhost"
    api_token: "myapitoken"
    username: "testuser"
  register: result

- debug:
    var: result.user_details

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

changed

boolean

Whether the module made changes (always false for get operations)

Returned: always

Sample: false

failed

boolean

Whether the module failed

Returned: always

Sample: false

user_details

dictionary

Complete user account details and profile information

Returned: always

disabled

boolean

Whether the user account is disabled

Returned: always

Sample: false

displayName

string

Display name of the user

Returned: always

Sample: "Administrator"

groups

list / elements=string

Available groups list

Returned: always

Sample: ["Administrators", "DHCP Administrators", "DNS Administrators"]

memberOfGroups

list / elements=string

List of groups the user is a member of

Returned: always

Sample: ["Administrators"]

previousSessionLoggedOn

string

Timestamp of previous session login (ISO 8601 format)

Returned: always

Sample: "2022-09-16T13:22:45.671Z"

previousSessionRemoteAddress

string

Remote IP address of previous session

Returned: always

Sample: "127.0.0.1"

recentSessionLoggedOn

string

Timestamp of most recent session login (ISO 8601 format)

Returned: always

Sample: "2022-09-18T09:55:26.9800695Z"

recentSessionRemoteAddress

string

Remote IP address of most recent session

Returned: always

Sample: "127.0.0.1"

sessions

list / elements=dictionary

List of active user sessions

Returned: always

isCurrentSession

boolean

Whether this is the current session

Returned: always

lastSeen

string

Last seen timestamp (ISO 8601 format)

Returned: always

lastSeenRemoteAddress

string

Last seen remote IP address

Returned: always

lastSeenUserAgent

string

Last seen user agent string

Returned: always

partialToken

string

Partial token identifier

Returned: always

tokenName

string

Name of the API token (if applicable)

Returned: when type is ApiToken

type

string

Session type (Standard or ApiToken)

Returned: always

username

string

Username of the session

Returned: always

sessionTimeoutSeconds

integer

Session timeout in seconds

Returned: always

Sample: 1800

username

string

Username of the user account

Returned: always

Sample: "admin"

Authors

  • Frank Muise (@effectivelywild)