ansible.builtin.urlsplit (v2.16.5) — filter

get components from URL

| "added in version" 2.4 of ansible.builtin"

Authors: unknown

Install Ansible via pip

Install with pip install ansible-core==2.16.5

Description

Split a URL into its component parts.

Inputs

    
query:
    choices:
    - fragment
    - hostname
    - netloc
    - password
    - path
    - port
    - query
    - scheme
    - username
    description: Specify a single component to return.
    type: str

_input:
    description: URL string to split.
    required: true
    type: str

Outputs

_value:
  description:
  - A dictionary with components as keyword and their value.
  - If O(query) is provided, a string or integer will be returned instead, depending
    on O(query).
  type: any