Skip to content

find subnets containing an IP address using API #2388

@payam124

Description

@payam124

I have a use case which I expected subnets/search/ would be the answer, but it wasn't and it didn't work.
I want to search for a specific IP address and if IP address has been not defined I would like to get the most specific defined subnet which contains that specific IP.
in the UI, when the user search for an IP, the system works exactly in this way. But I was not able to find the appropriate API call for such query. Using search in subnets
/api/ApplicationID/subnets/search/[IP]/
also returns {"code":400,"success":0,"message":"Subnet Id must be numeric (search)","time":0.01}
checking the code, seems nothing is there for "search" in the code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions