Datasets at data.sfgov.org and Lobbyist Database API
Since January 2010, lobbyists registered with the Ethics Commission have been required to file monthly electronic disclosure statements that include contact information, client lists, activity expenses, contacts of public officials, political contributions, and payments promised by clients. Each filing is stored in a database administered by the Ethics Commission. There are a variety of ways to access the Ethics Commission's lobbyist database:
- The contents of the disclosure statements can be searched or browsed on the Ethics Commission's lobbyist web site.
- The San Francisco Data web site at data.sfgov.org provides access to the data in a spreadsheet format that may be filtered and sorted online. See below for more information about the datasets at data.sfgov.org.
- Application developers can access the lobbyist database via an application programming interface. See below for more information about the API methods.
Lobbyist Datasets on data.sfgov.org
The following lobbyist datasets are available from data.sfgov.org. These datasets can be embedded into your own web site, built into charts, or downloaded into a variety of formats. See the blue menu above each dataset for more options.
Each dataset at data.sfgov.org is updated nightly.
- Lobbyist Map & Directory
- Client Map & Directory
- Lobbyists Grouped by Client
- Activity Expenses
- Political Contributions
- Contacts of Public Officials Calendar
- Payments Promised by Clients Calendar
Lobbyist API
The Lobbyist API provides application developers with access to download the contents of each lobbyist filing. The API provides live access to the Commission's lobbyist database and always provides the most up-to-date information.
The API returns Javascript Object Notation (JSON) from GET requests. The following methods are accessible from the API:
Insert the required variable in the URL where { } are provided below. The { } should be removed from the URL after inserting a variable.
API Version 1.1
Change Notes
- Updated JSON formatting
- Changed date format to ISO8601
All Filers by Year
This method returns all lobbyists that have filed at least one statement in the calendar year and includes contact information, filer ID, and current status.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filers/{year}
All Filings by Filer
This method returns a list of all filings filed by a lobbyist filer with the Commission. The lookup filer ID is obtained using the prior method.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filers/{filerId}/Filings
All Clients and Entities Reported on a Filing
These methods return all clients or entities reported on a particular filing. The filing ID is obtained using the prior method. A "Full Name" is the name of the client or entity as reported by the lobbyist. The "Mapped Name" is the name of the client or entity as corrected by Commission staff for the purposes of consistent spelling or mapping Aides to the correct member of the Board of Supervisors.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filings/{filingId}/Clients
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filings/{filingId}/Entities
All Contacts of a Public Official, Political Contributions, Activity Expenses, and Payments Promised by Clients Reported on a Filing
These methods return all Contacts of a Public Official, Political Contributions, Activity Expenses, and Payments Promised by Clients reported on a particular filing. The filing ID is obtained using the "All Filings by Filer" method.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filings/{filingId}/ContactsOfPublicOfficials
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filings/{filingId}/PoliticalContributions
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filings/{filingId}/ActivityExpenses
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v11/Filings/{filingId}/PaymentsPromisedByClients
Lobbyist Photos
At the time of registration with the Ethics Commission, lobbyists must supply a digital color photograph of the lobbyist's head and shoulders. All photos are stored in JPEG format at 130 x 150 pixels. Lobbyist photographs are stored using the following URL format:
- https://netfile.com/Sunlight/sf/lobbyist/picture/{year}/1/{filerId}
Monitor New Lobbyist Filings
New lobbyist filings can also be tracked by monitoring the following RSS feed. The feed is updated when a new filing is accessible in the database.
- https://netfile.com/Sunlight/sf/Lobbyist/FilingRSSFeed
API Version 1.0
All Filers by Year
This method returns all lobbyists that have filed at least one statement in the calendar year and includes contact information, filer ID, and current status.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filers/{year}
All Filings by Filer
This method returns a list of all filings filed by a lobbyist filer with the Commission. The lookup filer ID is obtained using the prior method.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filers/{filerId}/Filings
All Clients and Entities Reported on a Filing
These methods return all clients or entities reported on a particular filing. The filing ID is obtained using the prior method. A "Full Name" is the name of the client or entity as reported by the lobbyist. The "Mapped Name" is the name of the client or entity as corrected by Commission staff for the purposes of consistent spelling or mapping Aides to the correct member of the Board of Supervisors.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filings/{filingId}/Clients
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filings/{filingId}/Entities
All Contacts of a Public Official, Political Contributions, Activity Expenses, and Payments Promised by Clients Reported on a Filing
These methods return all Contacts of a Public Official, Political Contributions, Activity Expenses, and Payments Promised by Clients reported on a particular filing. The filing ID is obtained using the "All Filings by Filer" method.
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filings/{filingId}/ContactsOfPublicOfficials
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filings/{filingId}/PoliticalContributions
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filings/{filingId}/ActivityExpenses
- https://netfile.com/Sunlight/Api/Lobbyist/Sf/v10/Filings/{filingId}/PaymentsPromisedByClients
Lobbyist Photos
At the time of registration with the Ethics Commission, lobbyists must supply a digital color photograph of the lobbyist's head and shoulders. All photos are stored in JPEG format at 130 x 150 pixels. Lobbyist photographs are stored using the following URL format:
- https://netfile.com/Sunlight/sf/lobbyist/picture/{year}/1/{filerId}
Monitor New Lobbyist Filings
New lobbyist filings can also be tracked by monitoring the following RSS feed. The feed is updated when a new filing is accessible in the database.
- https://netfile.com/Sunlight/sf/Lobbyist/FilingRSSFeed
Assistance with the API
For additional assistance, please contact the Ethics Commission at ethics.commission@sfgov.org or at 415-252-3100.