Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add API contract GET recruiter information #75

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
129 changes: 93 additions & 36 deletions members/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@
Same as the [user](https://github.com/Real-Dev-Squad/website-api-contracts/tree/main/users#user-object) object
## Recruiter Object

```
```json
{
'company': string,
'first_name': string,
'last_name': string,
'designation': string,
'reason': string,
'email': string,
'currency': string,
'package': number
"company": "string",
"first_name": "string",
"last_name": "string",
"designation": "string",
"reason": "string",
"email": "string",
"currency": "string",
"package": "number"
}
```

Expand Down Expand Up @@ -43,19 +43,25 @@ Returns all members in the system.
- **Success Response:**
- **Code:** 200
- **Content:**

```
{
message: 'Members returned successfully!'
members: [
{<member_object>}
]
}
```
```json
{
"message": "Members returned successfully!",
"members": [
"<member_object>"
]
}
```

- **Error Response:**
- **Code:** 500
- **Content:** `{ 'statusCode': 500, 'error': 'Internal Server Error', 'message': 'Something went wrong. Please contact admin' }`
- **Content:**
```json
{
"statusCode": 500,
"error": "Internal Server Error",
"message": "Something went wrong. Please contact admin"
}
```

## **GET /members/idle**

Expand All @@ -74,19 +80,25 @@ Returns all inactive/idle members in the system.
- **Success Response:**
- **Code:** 200
- **Content:**

```
{
message: 'Idle members returned successfully!'
members: [
<username>
]
}
```
```json
{
"message": "Idle members returned successfully!",
"members": [
"<username>"
]
}
```

- **Error Response:**
- **Code:** 500
- **Content:** `{ 'statusCode': 500, 'error': 'Internal Server Error', 'message': 'Something went wrong. Please contact admin' }`
- **Content:**
```json
{
"statusCode": 500,
"error": "Internal Server Error",
"message": "Something went wrong. Please contact admin"
}
```

## POST /members/intro/:username
Creates new request for member introduction
Expand All @@ -104,13 +116,58 @@ Creates new request for member introduction
- **Success Response:**
- **Code:** 200
- **Content:**
```
{
message: 'Request Submission Successful!!'
id: <new unique submission id>
}
```
```json
{
"message": "Request Submission Successful!!",
"id": "<new unique submission id>"
}
```

- **Error Response:**
- **Code:** 500
- **Content:** `{ 'statusCode': 500, 'error': 'Internal Server Error', 'message': 'An internal server error occurred' }`
- **Content:**
```json
{
"statusCode": 500,
"error": "Internal Server Error",
"message": "An internal server error occurred"
}
```

## **GET /members/intro/**

Returns all requests for member introduction by recruiter in the system.

- **Params**
None
- **Query**
None
- **Body**
None
- **Headers**
None
- **Cookie**
None
- **Success Response:**
- **Code:** 200
- **Content:**
```json
{
"message": "Recruiters returned successfully!",
"recruiters": [
"<recruiter_object>",
"<recruiter_object>"
]
}
```

- **Error Response:**
- **Code:** 500
- **Content:**
```json
{
"statusCode": 500,
"error": "Internal Server Error",
"message": "Something went wrong. Please contact admin"
}
```