Skip to content

pallavdata/socialmedia-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

In settings.py SECRET_KEY is not defined

SIMPLE_JWT = {
"ACCESS_TOKEN_LIFETIME": timedelta(days=),
"REFRESH_TOKEN_LIFETIME":timedelta(days=)
You also have to define days to use JWT auth. Its a expiry (of jwt token) in days you can make it seconds or minutes also.




It is not trained with many images only 7000 (3500- gun image , 3500- other image)

if more then 0.5 then it could be a gun else not a gun

trained in low image size which is 120x120 {resize it yourself one by one or use cv2.resize)

100 times epoch mean 100 times studied all images

at the time 98% accuracy - 80% test accuracy which is very low




URLS:
-POST /api/reg/staff - registration of the staff members

-POST /api/reg- user registration

- POST /api/authenticate - JWT token.
- INPUT: Email, Password
- RETURN: JWT token

- POST /api/follow/{id} authenticated user follow user with {id}

- POST /api/unfollow/{id} authenticated user unfollow a user with {id}

- GET /api/user should authenticated user not necessary account holder return the respective user profile. Like you can see other likes and followers if you are login in insta.
- RETURN: User Name, number of followers & followings.

- POST api/posts/ would add a new post created by the authenticated user.
- Input: Title, Description
- RETURN: Post-ID, Title, Description, Created Time(UTC).

- DELETE api/posts/{id} would delete post with {id} created by the authenticated user.

- POST /api/like/{id} would like the post with {id} by the authenticated user.

- POST /api/unlike/{id} would unlike the post with {id} by the authenticated user.

- POST /api/comment/{id} add comment for post with {id} by the authenticated user.
- Input: Comment
- Return: Comment-ID

- GET api/posts/{id} would return a single post with {id} populated with its number of likes and comments

- GET /api/all_posts would return all posts created by authenticated user sorted by post time.
- RETURN: For each post return the following values
- id: ID of the post
- title: Title of the post
- desc: Description of the post
- created_at: Date and time when the post was created
- all comments: Array of comments, for the particular post
- likes: Number of likes for the particular post

- GET /api/all would return all posts created by authenticated user sorted by post time.
- RETURN: For each post return the following values
- full name
- id: ID of the post
- title: Title of the post
- desc: Description of the post
- created_at: Date and time when the post was created
- all comments: Array of comments, for the particular post
- likes: Number of likes for the particular post
- following
- followers

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published