Everything that you can do in the UI can be done using our API!
REST API
The SpringServe API is a simple REST API that you can use no matter what your favorite programming language is.
Base Url
https://videoconsole.springserve.com
SpringServe SDK
For your (and our) convenience we have created a python interface to our API.
...
Code Block |
---|
In [3]: springserve.supply_tags.get? Signature: springserve.supply_tags.get(path_param=None, reauth=False, **query_params) Docstring: Make a get request to this api service. Allows you to pass in arbitrary query paramaters. Examples:: # get all supply_tags tags = springserve.supply_tags.get() for tag in tags: print tag.id, tag.name # get one supply tag tag = springserve.supply_tag.get(1) print tag.id, tag.name # get by many ids tags = springserve.supply_tags.get(ids=[1,2,3]) # get users that are account_contacts (ie, using query string # params) users = springserve.users.get(account_contact=True) File: /usr/local/lib/python2.7/site-packages/springserve/__init__.py Type: instancemethod |
Examples of simple functions to replace messy requests, plus more tab completion:
Code Block |
---|
# get a supply tag by its id
In [4]: tag = springserve.supply_tags.get(123)
In [5]: tag.<tab>
tag.active tag.domain_list_ids tag.player_size_targeting
tag.supply_partner_id
tag.allowed_player_sizes tag.domain_targeting tag.rate
tag.supply_type
tag.country_codes tag.id tag.raw
tag.country_targeting tag.name tag.save
tag.demand_tag_priorities tag.payment_terms tag.supply_group_id
# see contents of a field
In [6]: tag.name
Out [6]: "My test tag"
# change the field and save it
In [7]: tag.name = "My new test tag"
In [8]: resp = tag.save() |
If you have multiple logins for SpringServe, you can set credentials:
Code Block | ||||
---|---|---|---|---|
| ||||
springserve.set_credentials(user='blah@blah.com', password="mypassword", base_url='https://console.springserve.com/api/v0') |
SDK will allow you to work more efficiently, we highly encourage you to use it for all your SpringServe API needs.
Download it from Github
End points
You can find information about all of the different API end points below. We show examples of using the REST API as well as SDK for all of them.
...