Option to add a Custom Header to a Request and Retrieve Response Header Value

Open
#331 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
csharp
Domain
api

Research direction

Start by tracing the request path around the proposed query.GetHeaders() call and identify how responses are exposed to C# callers. Define how callers would add custom request headers and retrieve a selected response header, then confirm the behavior with a focused C# usage example or test.

Written by the indexing model from the issue text.

Description

area: postgrest feature

Feature request

Is your feature request related to a problem? Please describe.

I'm currently working on a project using Supabase in C#, and I need to add a custom header to my requests. Additionally, I want to retrieve a specific header value from the response.

I've been able to make basic requests, but I'm not sure how to modify the request to include a custom header or how to access the headers from the response. Could anyone provide an example or guidance on how to achieve this in C#?

Describe the solution you'd like

I thinking like this
query.GetHeaders().TryAdd("prefer", "count=exact");

Describe alternatives you've considered

Additional context

Dominant language
C#
Stars
701
Forks
106
Avg merge
16h 35m
Merged PRs (30d)
45

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from supabase/supabase-csharp

All issues in supabase/supabase-csharp

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.