Extending Superdesk

Changed in version 1.6.

Adding new Search Provider

You have to implement a new SearchProvider and register it within superdesk:

import superdesk

class FooSearchProvider(superdesk.SearchProvider):

    label = 'Foo'

    def find(self, query):
        return [{'headline': 'Static list'}]

def init_app(app):
    superdesk.register_search_provider('foo', provider_class=FooSearchProvider)

This way it will add a new option to subscribers settings.


Don’t forget to add such module into INSTALLED_APPS.

Search Provider API

class superdesk.SearchProvider(provider)

Base class for Search Providers.

You can use self.provider to get config data.


Get single item.

Get an item before archiving it. Should contain all metadata.

Parameters:guid – item guid

Fetch binary using given href.

Href is from renditions dict.

Parameters:href – binary href

Find items using query.

This must return cursor like object.

Parameters:query – query dict
label = 'unknown'

Provider Type Label