//native
/**
* Submit your application!
* This endpoint will let you apply to a job at ReadMe programatically, without having to go through our UI!
*/
export async function main(auth: RT.Readme, body: Body) {
const url = new URL(`https://api.readme.com/v2/apply`)
const response = await fetch(url, {
method: 'POST',
headers: {
'Content-Type': 'application/json',
Authorization: 'Bearer ' + auth.apiKey
},
body: JSON.stringify(body)
})
if (!response.ok) {
const text = await response.text()
throw new Error(`${response.status} ${text}`)
}
return await response.json()
}
/* eslint-disable */
/**
* This file was automatically generated by json-schema-to-typescript.
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
* and run json-schema-to-typescript to regenerate this file.
*/
export interface Body {
/**
* Your full name
*/
name: string
/**
* A valid email we can reach you at.
*/
email?: string
/**
* The job you're looking to apply for (https://readme.com/careers).
*/
job: string
/**
* Learn more at https://lgbtlifecenter.org/pronouns/
*/
pronouns?: string
/**
* What have you been up to the past few years?
*/
linkedin?: string
/**
* Or Bitbucket, GitLab or anywhere else your code is hosted!
*/
github?: string
/**
* What should we know about you?
*/
coverLetter?: string
/**
* If you set this to true, we will not actually apply you to the job.
*/
dont_really_apply?: boolean
}
Submitted by hugo697 235 days ago