# Domains ## Get Domain Details `client.Intel.Domains.Get(ctx, params) (*Domain, error)` **get** `/accounts/{account_id}/intel/domain` Gets security details and statistics about a domain. ### Parameters - `params DomainGetParams` - `AccountID param.Field[string]` Path param: Identifier. - `Domain param.Field[string]` Query param ### Returns - `type Domain struct{…}` - `AdditionalInformation DomainAdditionalInformation` Additional information related to the host name. - `SuspectedMalwareFamily string` Suspected DGA malware family. - `Application DomainApplication` Application that the hostname belongs to. - `ID int64` - `Name string` - `ContentCategories []DomainContentCategory` - `ID int64` - `Name string` - `SuperCategoryID int64` - `Domain string` - `InheritedContentCategories []DomainInheritedContentCategory` - `ID int64` - `Name string` - `SuperCategoryID int64` - `InheritedFrom string` Domain from which `inherited_content_categories` and `inherited_risk_types` are inherited, if applicable. - `InheritedRiskTypes []DomainInheritedRiskType` - `ID int64` - `Name string` - `SuperCategoryID int64` - `PopularityRank int64` Global Cloudflare 100k ranking for the last 30 days, if available for the hostname. The top ranked domain is 1, the lowest ranked domain is 100,000. - `ResolvesToRefs []DomainResolvesToRef` Specifies a list of references to one or more IP addresses or domain names that the domain name currently resolves to. - `ID string` STIX 2.1 identifier: https://docs.oasis-open.org/cti/stix/v2.1/cs02/stix-v2.1-cs02.html#_64yvzeku5a5c. - `Value string` IP address or domain name. - `RiskScore float64` Hostname risk score, which is a value between 0 (lowest risk) to 1 (highest risk). - `RiskTypes []DomainRiskType` - `ID int64` - `Name string` - `SuperCategoryID int64` ### Example ```go package main import ( "context" "fmt" "github.com/cloudflare/cloudflare-go" "github.com/cloudflare/cloudflare-go/intel" "github.com/cloudflare/cloudflare-go/option" ) func main() { client := cloudflare.NewClient( option.WithAPIToken("Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY"), ) domain, err := client.Intel.Domains.Get(context.TODO(), intel.DomainGetParams{ AccountID: cloudflare.F("023e105f4ecef8ad9ca31a8372d0c353"), }) if err != nil { panic(err.Error()) } fmt.Printf("%+v\n", domain.AdditionalInformation) } ``` #### Response ```json { "errors": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "messages": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "success": true, "result": { "additional_information": { "suspected_malware_family": "" }, "application": { "id": 0, "name": "CLOUDFLARE" }, "content_categories": [ { "id": 155, "name": "Technology", "super_category_id": 26 } ], "domain": "cloudflare.com", "inherited_content_categories": [ { "id": 0, "name": "name", "super_category_id": 0 } ], "inherited_from": "inherited_from", "inherited_risk_types": [ { "id": 0, "name": "name", "super_category_id": 0 } ], "popularity_rank": 0, "resolves_to_refs": [ { "id": "ipv4-addr--baa568ec-6efe-5902-be55-0663833db537", "value": "192.0.2.0" } ], "risk_score": 0, "risk_types": [ { "id": 0, "name": "name", "super_category_id": 0 } ] } } ``` ## Domain Types ### Domain - `type Domain struct{…}` - `AdditionalInformation DomainAdditionalInformation` Additional information related to the host name. - `SuspectedMalwareFamily string` Suspected DGA malware family. - `Application DomainApplication` Application that the hostname belongs to. - `ID int64` - `Name string` - `ContentCategories []DomainContentCategory` - `ID int64` - `Name string` - `SuperCategoryID int64` - `Domain string` - `InheritedContentCategories []DomainInheritedContentCategory` - `ID int64` - `Name string` - `SuperCategoryID int64` - `InheritedFrom string` Domain from which `inherited_content_categories` and `inherited_risk_types` are inherited, if applicable. - `InheritedRiskTypes []DomainInheritedRiskType` - `ID int64` - `Name string` - `SuperCategoryID int64` - `PopularityRank int64` Global Cloudflare 100k ranking for the last 30 days, if available for the hostname. The top ranked domain is 1, the lowest ranked domain is 100,000. - `ResolvesToRefs []DomainResolvesToRef` Specifies a list of references to one or more IP addresses or domain names that the domain name currently resolves to. - `ID string` STIX 2.1 identifier: https://docs.oasis-open.org/cti/stix/v2.1/cs02/stix-v2.1-cs02.html#_64yvzeku5a5c. - `Value string` IP address or domain name. - `RiskScore float64` Hostname risk score, which is a value between 0 (lowest risk) to 1 (highest risk). - `RiskTypes []DomainRiskType` - `ID int64` - `Name string` - `SuperCategoryID int64` # Bulks ## Get Multiple Domain Details `client.Intel.Domains.Bulks.Get(ctx, params) (*[]DomainBulkGetResponse, error)` **get** `/accounts/{account_id}/intel/domain/bulk` Same as summary. ### Parameters - `params DomainBulkGetParams` - `AccountID param.Field[string]` Path param: Identifier. - `Domain param.Field[[]string]` Query param: Accepts multiple values like `?domain=cloudflare.com&domain=example.com`. ### Returns - `type DomainBulkGetResponseEnvelopeResult []DomainBulkGetResponse` - `AdditionalInformation DomainBulkGetResponseAdditionalInformation` Additional information related to the host name. - `SuspectedMalwareFamily string` Suspected DGA malware family. - `Application DomainBulkGetResponseApplication` Application that the hostname belongs to. - `ID int64` - `Name string` - `ContentCategories []DomainBulkGetResponseContentCategory` - `ID int64` - `Name string` - `SuperCategoryID int64` - `Domain string` - `InheritedContentCategories []DomainBulkGetResponseInheritedContentCategory` - `ID int64` - `Name string` - `SuperCategoryID int64` - `InheritedFrom string` Domain from which `inherited_content_categories` and `inherited_risk_types` are inherited, if applicable. - `InheritedRiskTypes []DomainBulkGetResponseInheritedRiskType` - `ID int64` - `Name string` - `SuperCategoryID int64` - `PopularityRank int64` Global Cloudflare 100k ranking for the last 30 days, if available for the hostname. The top ranked domain is 1, the lowest ranked domain is 100,000. - `RiskScore float64` Hostname risk score, which is a value between 0 (lowest risk) to 1 (highest risk). - `RiskTypes []DomainBulkGetResponseRiskType` - `ID int64` - `Name string` - `SuperCategoryID int64` ### Example ```go package main import ( "context" "fmt" "github.com/cloudflare/cloudflare-go" "github.com/cloudflare/cloudflare-go/intel" "github.com/cloudflare/cloudflare-go/option" ) func main() { client := cloudflare.NewClient( option.WithAPIToken("Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY"), ) bulks, err := client.Intel.Domains.Bulks.Get(context.TODO(), intel.DomainBulkGetParams{ AccountID: cloudflare.F("023e105f4ecef8ad9ca31a8372d0c353"), }) if err != nil { panic(err.Error()) } fmt.Printf("%+v\n", bulks) } ``` #### Response ```json { "errors": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "messages": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "result": [ { "additional_information": { "suspected_malware_family": "" }, "application": { "id": 0, "name": "CLOUDFLARE" }, "content_categories": [ { "id": 155, "name": "Technology", "super_category_id": 26 } ], "domain": "cloudflare.com", "inherited_content_categories": [ { "id": 0, "name": "name", "super_category_id": 0 } ], "inherited_from": "inherited_from", "inherited_risk_types": [ { "id": 0, "name": "name", "super_category_id": 0 } ], "popularity_rank": 0, "risk_score": 0, "risk_types": [ { "id": 0, "name": "name", "super_category_id": 0 } ] } ], "success": true, "result_info": { "count": 1, "page": 1, "per_page": 20, "total_count": 2000 } } ```