Skip to main content

A thin wrapper around requests to interact with the Simple Intel Platform (SIP).

Project description

pysip

A thin wrapper around requests to interact with the Simple Intel Platform (SIP).

Usage

import pysip

# Connect to SIP
sip_client = pysip.Client('localhost:4443', '11111111-1111-1111-1111-111111111111', verify=False)

# Example POST request
# Add an indicator and ignore any 409 Conflict error if the indicator already exists.
try:
    data = {'type': 'IP', 'value': '127.0.0.1'}
    sip_client.post('/api/indicators', data)
except pysip.ConflictError:
    pass

# Example GET request
# Get all of the indicators with the "Analyzed" status in "bulk" mode.
indicators = sip_client.get('/api/indicators?status=Analyzed&bulk=true')

# Example PUT request
# Update an indicator's status.
data = {'status': 'Informational'}
result = sip_client.put('/api/indicators/1', data)

# Example DELETE request
# Delete an indicator.
result = sip_client.delete('/api/indicators/1')

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pysip-1.1.0.tar.gz (4.1 kB view hashes)

Uploaded Source

Built Distribution

pysip-1.1.0-py3-none-any.whl (7.3 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page