FeaturesTemplatesShowcaseTownie
AI
BlogDocsPricing
Log inSign up
nbbaier
nbbaiersubmitPR
Public
Like
submitPR
Home
Code
2
README.md
main.tsx
Branches
1
Pull requests
Remixes
History
Environment variables
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
Sign up now
Code
/
Code
/
Search
README.md

Submit a PR from Val Town

This val provides a (very) thin wrapper around the GH rest API methods for creating a pull request. It handles the creation of a Octokit client for you.

Usage

Create val
import { submitPR } from "https://esm.town/v/nbbaier/submitPR"; await submitPR(Deno.env.get("GH_REPO_TOKEN"), { owner: "nbbaier", repo: "test-ground", head: "branch_2", base: "main", title: "trying another PR", body: "cool stuff, take a look", });

Parameters

The function takes two parameters: your gh access token and an object that's identical to the object submitted to the gh API. See GH's documentation for more info!

Code
README.mdmain.tsx
Go to top
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Product
FeaturesPricing
Developers
DocsStatusAPI ExamplesNPM Package Examples
Explore
ShowcaseTemplatesNewest ValsTrending ValsNewsletter
Company
AboutBlogCareersBrandhi@val.town
Terms of usePrivacy policyAbuse contact
© 2025 Val Town, Inc.