Document your Functions

Guidelines for how to document Funciton Store functions.

Overview

This document provides useful guidelines for how to document the functions you create and publish in Function Store. The intent of these guidelines is to help maintain consistency across the documentation of functions.

As a function developer, you have the opportunity to deliver functions that rise to the top of the marketplace. To do so, you'll need to meet high expectations for quality and functionality.

How to document functions?

You should structure the documentation into 4 main sections:

  1. How this function works

    • In an introductory paragraph, explain what the function is used for, and what are the use cases.

    • Use Level 2 heading for naming this section.

    • Place the paragraph just after the title.

    • Keep it concise and short. Use only one to three small paragraphs.

  2. Prerequisites

    • What you need to know before installing the function.

    • Use Level 2 heading for naming this section.

    • The information placed in this section is a bulleted list that you can start with the following format: "To complete this tutorial, you will need:"

  3. Function details

    • Describe the installation process in a logical sequence. You can do so by using an article body structure or dividing the process into steps (step-by-step). Note that not all function documentation requires a Function details section.

    • Use Level 2 heading for naming this section.

    • Include commands, code blocks, and function details, and provide explanations that not only describe what to do but also why you’re doing it this way.

    • Explain each of the environment variables.

    • Add parameters and properties if necessary. Use tables to better organize this type of information.

    • In case your function documentation needs a procedural explanation, start each process or step with a title. Use the following format:

      • Title of the process in Level 3 heading, if you use an article body structure.

      • Title of the step in Level 3 heading, if you use a step-by-step structure. Begin each step with the word Step and a number, followed by a colon (:), and then place the title.

  4. Resources

    • Add links from sources that support the documentation of the function, as links to third-party services that use the function.

    • Use Level 2 heading for naming this section.

    • The information placed in this section is a bulleted list.

You can add to these sections block codes, blockquotes, images, tables, and other elements. For more information about formatting these elements, see Editorial guidelines.

Last updated