Skip to main content

Queries the domain-level inbound allowlist/blocklist

GET/v2/messageRules/allowBlockLists

Queries the inbound allowlist/blocklist entries at the domain level for the current organization. Specifies either the allowlist or the blocklist using type, and controls the return scope with pagination parameters.

Request​

Query parameters

    type enum

    Possible values: [ALLOW, BLOCK]

    • ALLOW:
    • BLOCK:
    keyword string

    Keyword filter that supports fuzzy search by email address, domain, or IP address.

Response

    entities object[]

    List of allowlist/blocklist entries.

    id string

    Unique identifier of the entry, read-only.

    type enum

    Entry type.

    • EMAIL: Email address
    • DOMAIN_NAME: Domain name
    • IPV4ADDRESS: IPv4 address
    • IPV4ADDRESSRANGE: IPv4 address range
    • IPV6ADDRESS: IPv6 address
    • IPV6ADDRESSRANGE: IPv6 address range
    • IPREGION: IP region

    Possible values: [EMAIL, DOMAIN_NAME, IPV4ADDRESS, IPV4ADDRESSRANGE, IPV6ADDRESS, IPV6ADDRESSRANGE, IPREGION]

    email string

    Email address. Required when the type is EMAIL.

    domain string

    Domain name. Required when type is DOMAIN_NAME.

    ipAddress string

    IP address. When the type is IPV4ADDRESS, fill in, for example, "192.168.1.1". When the type is IPV6ADDRESS, fill in, for example, "2001:db8::1".

    ipAddressRange object

    IP address range, required when type is IPV4ADDRESSRANGE or IPV6ADDRESSRANGE.

    begin string

    Start address of the IP range, such as "192.168.1.1" or "2001:db8::1".

    end string

    Ending IP address of the range, for example, "192.168.1.255" or "2001:db8::ffff".

    ipRegion object

    IP region area. Required when type is IPREGION.

    countryCode string

    Country code, such as CN.

    provinceCode string

    Province code.

    cityCode string

    City code.

Errors

401

Access is unauthorized. Please check whether the correct authorization token is passed.

403

No API access permission. Please complete the relevant authorization on the application management page of the domain administrator.