Overview
API Concepts Manage API Key
Internet Data
DNSIQ® WHOISIQ™ SSL Certificates Blacklist Lookup Host Attributes
Attack Analytics
Newly Observed Domains Newly Observed Hosts Malware Phishing Scam Content
Digital Footprint
Global Inventory API Global Inventory Schema
Coming Soon
Enrich
PassiveTotal
Actions Artifact Enrichment Exposed Services Monitor Project SSL Certificates Tag Artifact Trackers Host Attributes Passive DNS Whois Bulk Enrichment
Additional Resources
Workspace Management API
RiskIQ.com

Tag Artifact

 

What It Looks Like

Get Artifact Tags

Retrieve the tags of an artifact or artifacts.

Curl Example

# As an URL parameter
$ curl -u $USERNAME:$KEY 'https://api.riskiq.net/pt/v2/artifact/tag?artifact=a9969326-4310-175d-d422-e83a36edaae0'
			

Parameters

Field Field Type Description
artifactUUID[] the artifact id or ids to list

Sample Response

{
    "user_tags": [
        "mytag"
    ],
    "tags": [
        "registered",
        "mytag"
    ],
    "system_tags": [
        "registered"
    ],
    "tag_meta": {
        "mytag": {
            "created_at": "2017-03-30T01:05:12.629000",
            "creator": "sim.gretina@example.org"
        }
    },
    "success": true
}
			

Remove Artifact Tags

Remove a set of tags from an artifact or artifacts.

Curl Example

$ curl -u $USERNAME:$KEY 'https://api.riskiq.net/pt/v2/artifact/tag' -XDELETE -H "Content-Type: application/json" --data '{"artifact": "a9969326-4310-175d-d422-e83a36edaae0", "tags": ["foo"]}'

Parameters

Field Field Type Description
artifactUUID[] the artifact id or ids to list
tagsString[] the tags or tag to delete (list or str)

JSON Request

{
    "artifact": "a9969326-4310-175d-d422-e83a36edaae0",
    "tags": [
        "foo"
    ]
}
            

Sample Response

{
    "tags": [
        "registered",
        "bar",
        "baz"
    ],
    "system_tags": [
        "registered"
    ],
    "tag_meta": {
        "bar": {
            "creator": "sim.gretina@example.org",
            "created_at": "2017-04-17T19:28:40.284000"
        },
        "baz": {
            "creator": "sim.gretina@example.org",
            "created_at": "2017-04-17T19:30:21.507000"
        }
    },
    "success": true,
    "user_tags": [
        "bar",
        "baz"
    ]
}
			

Set Artifact Tags

Set the tags of an artifact or artifacts.

Curl Example

$ curl -u $USERNAME:$KEY 'https://api.riskiq.net/pt/v2/artifact/tag' -XPUT -H "Content-Type: application/json" --data '{"artifact": "a9969326-4310-175d-d422-e83a36edaae0", "tags": ["foo", "bar"]}'

Parameters

Field Field Type Description
artifactUUID[] the artifact id or ids to list
tagsString[] the tags or tag to set (list or str)

JSON Request

{
    "artifact": "a9969326-4310-175d-d422-e83a36edaae0",
    "tags": [
        "foo",
        "bar"
    ]
}
            

Sample Response

{
    "tags": [
        "registered",
        "foo",
        "bar"
    ],
    "system_tags": [
        "registered"
    ],
    "tag_meta": {
        "bar": {
            "creator": "sim.gretina@example.org",
            "created_at": "2017-04-17T19:28:40.284000"
        },
        "foo": {
            "creator": "sim.gretina@example.org",
            "created_at": "2017-04-17T19:28:40.284000"
        }
    },
    "success": true,
    "user_tags": [
        "bar",
        "foo"
    ]
}
			

Update Artifact Tags

Add tags to an artifact or artifacts.

Curl Example

$ curl -u $USERNAME:$KEY 'https://api.riskiq.net/pt/v2/artifact/tag' -XPOST -H "Content-Type: application/json" --data '{"artifact": "a9969326-4310-175d-d422-e83a36edaae0", "tags": ["baz"]}'

Parameters

Field Field Type Description
artifactUUID[] the artifact id or ids to update
tagsString[] the tags or tag to add (list or str)

JSON Request

{
    "artifact": "a9969326-4310-175d-d422-e83a36edaae0",
    "tags": [
        "baz"
    ]
}
            

Sample Response

{
    "tags": [
        "registered",
        "foo",
        "bar",
        "baz"
    ],
    "system_tags": [
        "registered"
    ],
    "tag_meta": {
        "bar": {
            "creator": "sim.gretina@example.org",
            "created_at": "2017-04-17T19:28:40.284000"
        },
        "foo": {
            "creator": "sim.gretina@example.org",
            "created_at": "2017-04-17T19:28:40.284000"
        },
        "baz": {
            "creator": "sim.gretina@example.org",
            "created_at": "2017-04-17T19:30:21.507000"
        }
    },
    "success": true,
    "user_tags": [
        "bar",
        "baz",
        "foo"
    ]
}