chore(postman): add collection and environment files

pull/12/head
Cullen 2023-07-09 18:53:29 -05:00
parent 853a35f0f3
commit 6269479955
2 changed files with 205 additions and 0 deletions

View File

@ -0,0 +1,190 @@
{
"info": {
"_postman_id": "a0aa8829-fd18-47fa-a50d-03c8193adb9a",
"name": "JobSpy",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "24144392"
},
"item": [
{
"name": "Search Jobs",
"request": {
"auth": {
"type": "bearer",
"bearer": [
{
"key": "token",
"value": "{{access_token}}",
"type": "string"
}
]
},
"method": "GET",
"header": [],
"url": {
"raw": "http://127.0.0.1:8000/api/v1/jobs?site_type=indeed&search_term=software intern&location=dallas&page=2",
"protocol": "http",
"host": [
"127",
"0",
"0",
"1"
],
"port": "8000",
"path": [
"api",
"v1",
"jobs"
],
"query": [
{
"key": "site_type",
"value": "indeed"
},
{
"key": "search_term",
"value": "software intern"
},
{
"key": "location",
"value": "dallas"
},
{
"key": "page",
"value": "2"
}
]
}
},
"response": []
},
{
"name": "Health",
"request": {
"auth": {
"type": "bearer",
"bearer": [
{
"key": "token",
"value": "{{access_token}}",
"type": "string"
}
]
},
"method": "GET",
"header": [],
"url": {
"raw": "http://127.0.0.1:8000/",
"protocol": "http",
"host": [
"127",
"0",
"0",
"1"
],
"port": "8000",
"path": [
""
]
}
},
"response": []
},
{
"name": "Token",
"event": [
{
"listen": "test",
"script": {
"exec": [
"var jsonData = JSON.parse(responseBody);",
"postman.setEnvironmentVariable(\"access_token\", jsonData.access_token)"
],
"type": "text/javascript"
}
}
],
"request": {
"method": "POST",
"header": [],
"body": {
"mode": "urlencoded",
"urlencoded": [
{
"key": "username",
"value": "cwatson",
"type": "text"
},
{
"key": "password",
"value": "mypass",
"type": "text"
}
]
},
"url": {
"raw": "http://127.0.0.1:8000/api/auth/token",
"protocol": "http",
"host": [
"127",
"0",
"0",
"1"
],
"port": "8000",
"path": [
"api",
"auth",
"token"
]
}
},
"response": []
},
{
"name": "Register",
"event": [
{
"listen": "test",
"script": {
"exec": [
"var jsonData = JSON.parse(responseBody);",
"postman.setEnvironmentVariable(\"access_token\", jsonData.access_token)"
],
"type": "text/javascript"
}
}
],
"request": {
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"username\": \"cwatson\",\n \"email\": \"cgwatson@smu.edu\",\n \"password\": \"mypass\",\n \"full_name\": \"cullen watson\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "http://127.0.0.1:8000/api/auth/register",
"protocol": "http",
"host": [
"127",
"0",
"0",
"1"
],
"port": "8000",
"path": [
"api",
"auth",
"register"
]
}
},
"response": []
}
]
}

View File

@ -0,0 +1,15 @@
{
"id": "a7ea6d58-8dca-4216-97a9-224dadc1e18f",
"name": "JobSpy",
"values": [
{
"key": "access_token",
"value": "",
"type": "any",
"enabled": true
}
],
"_postman_variable_scope": "environment",
"_postman_exported_at": "2023-07-09T23:51:36.709Z",
"_postman_exported_using": "Postman/10.15.8"
}