fortinet / fortinet.fortiflexvm / 2.2.0 / module / fortiflexvm_groups_nexttoken_info Get net available (unused) token. | "added in version" 1.0.0 of fortinet.fortiflexvm" Authors: Xinwei Du (@dux-fortinet)fortinet.fortiflexvm.fortiflexvm_groups_nexttoken_info (2.2.0) — module
Install with ansible-galaxy collection install fortinet.fortiflexvm:==2.2.0
collections: - name: fortinet.fortiflexvm version: 2.2.0
Returns first available token by asset folder or Configuration id (folder path, or config id or both can be specified in request).
- name: Get next available (unused) token hosts: localhost vars: username: "<your_own_value>" password: "<your_own_value>" tasks: - name: Get groups nexttoken fortinet.fortiflexvm.fortiflexvm_groups_nexttoken_info: username: "{{ username }}" password: "{{ password }}" # Please declare at least one of the following two arguments: accountId or configId. # You can comment at most one argument that you don't want to specify. configId: 22 # accountId: 12345 # Optional parameters folderPath: "My Assets" status: ["ACTIVE", "PENDING"] # "ACTIVE", "PENDING", "STOPPED", "EXPIRED" register: result - name: Display response ansible.builtin.debug: var: result.entitlements
status: description: Filter option. A list. Possible values are "ACTIVE", "PENDDING", "STOPPED" and "EXPIRED". elements: str type: list configId: description: - The ID of a Flex VM Configuration. Please declare at least one of the two arguments, accountId or configId. type: int password: description: - The password to authenticate. If not declared, the code will read the environment variable FORTIFLEX_ACCESS_PASSWORD. type: str username: description: - The username to authenticate. If not declared, the code will read the environment variable FORTIFLEX_ACCESS_USERNAME. type: str accountId: description: Account ID. Please declare at least one of the two arguments, accountId or configId. type: str folderPath: description: - Folder path. type: str
entitlements: contains: accountId: description: Account ID. returned: if specified account ID in the argument sample: 12345 type: int configId: description: The config ID of the entitlement. returned: always sample: 22 type: int description: description: The description of the entitlement. returned: always sample: VMs created for department A type: str endDate: description: The end date of the entitlement. returned: always sample: '2020-10-25 00:00:00' type: str serialNumber: description: The serial number of the entitlement. returned: always sample: FGVMELTM20000020 type: str startDate: description: The start date of the entitlement. returned: always sample: '2020-08-01 10:12:25' type: str status: description: The status of the entitlement. Possible values are "PENDING", "ACTIVE", "STOPPED" or "EXPIRED". returned: always sample: ACTIVE type: str token: description: The token of the entitlement. returned: always type: str tokenStatus: description: The token status of the entitlement. returned: always sample: NOTUSED type: str description: Next available (unused) token. This list only has one element. returned: always type: list