Introduction

HeyGov.js reference

This reference documents every object and method available in HeyGov’s browser-side JavaScript library, HeyGov.js.

The library is used and helpful for:

  • embedding or showing up the 311 Request widget

  • embed a venue with reservation functionality (beta)

  • enhance navigation for embedded events calendar (beta)

  • embed the Payments portal on a website (coming soon)

The script

<script src="https://edge.heygov.com/heygov.js" data-heygov-jurisdiction="town.com"></script>

This is the script to include a site for HeyGov functionality. Should be included on site footer.

It exposes the HeyGov object, which has these helpers:

Variables

Var
Type

jurisdiction

String

The HeyGov ID for this site

features

Array

List of features enabled for this HeyGov jurisdiction

Methods

Method

showHey311()

Display the Hey311 widget/dialog

hideHey311()

toggleHey311()

Last updated