Advanced Features

Description of some more advanced Features of Milkman

Description of some more advanced Features of Milkman

Code Folding

  • Folding is supported in response body area
  • Toolbar actions: expand all, collapse all, expand one level, collapse one level
  • Clicking on the line-symbol expands the node
  • Right-Clicking on the line-symbol expands the whole subtree

Example of code folding

Hotkeys

  • CTRL+ENTER - Execute Request
  • CTRL+N - New Request
  • CTRL+R - Rename Active Request
  • CTRL+W - Close Active Request
  • CTRL+S - Save Active Request
  • CTRL+E - Edit current Environment
  • CTRL+Space - Quick-Edit of Variables
  • ESC - Cancel running Request

Copy&Paste in Tables

  • You can CTRL+C selected rows to copy its value
  • You can CTRL+V multiple rows into a table

Example of Copy&Paste for tables

Quick Edit for Variables

  • You can highlight variables.
  • Clicking on it opens popup for modification/creation
  • ESC hides highlighting

Example of Quick-edit for variables

Keys

  • secret keys that should not be exported or synced can be setup using the key-symbol
  • currently, secret keys are only plain type keys, but will be e.g. oauth-keys etc
  • can be accessed using {{key:name-of-key}} variable

Libraries

you can register libraries to easily look-up and import services from a central registry, such as APIs.guru.

Example of setting up and using Libraries

Code Templates

  • you can define custom templates for every type of request yourself. Do you often need to write Spring Webclient code? setup some custom template for it. (you can do so in the options dialog)
  • Some predefined templates are available already. (see here)
  • Syntax is similar to mustache but enhanced with whitespace control. example:
curl -X {{httpMethod}}

{{_#headers.entries-}}
-H "{{name}}: {{value}}"
{{-/headers.entries_}}

{{url}}
  • Whitespace control:
    • {{- removes all whitespaces (including linebreaks) before the tag
    • {{_ removes all whitespaces (including linebreaks) before the tag and replaces it with one space
    • -}} removes all whitespaces (including linebreaks) after the tag
    • _}} removes all whitespaces (including linebreaks) after the tag and replaces it with one space

Insomnia Import

  • exported Collections (see Insomnia Documentation) can be imported into Milkman.
  • currently, Http, Websocket, event-stream, Grpc and Gql requests are supported
  • environments are also imported
  • :exclamation: There are some conceptual differences between insomnia and milkman though:
    • Insomnia root-level requests are imported into a collection with the name of the workspace
    • Insomnia environments overload each other based on a hierarchy. this is flattened on import.
    • Grpc requests refere to a shared file in the workspace. This is flattened in milkman (i.e. file-content is copied to each request refering to it)

Slack Integration

Slack-integration for milkman


Last modified June 7, 2024: update (ed33848)