Skip to content

Latest commit

 

History

History
23 lines (21 loc) · 593 Bytes

File metadata and controls

23 lines (21 loc) · 593 Bytes

This httpyac example is for a server project that serves the Supabase database.

Tokens are stored from the response, in an environment variable, with a set name.

If an error occurs, just repeat the step that saves the information to the variable.

Summary:

Use the @name decorator to assign a name. For example:

# @name Variables

Initialize global variables:

{{
  $global.accessToken=null;
  $global.refreshToken=null;
}}

Use global variables even in other .http files:

# @name me
GET /auth/me
Authorization: Bearer {{$global.accessToken}}