Giter Club home page Giter Club logo

mail-box-demo's Issues

Create api

As user
I want to have create message api
So that API has complete functionality

Description

Acceptance Criteria

  • tests

QA

Export task

As a Dev
I want to write an export task
So that export from json arbitrary file to db

Describe
To seed the database with some example messages there is a JSON file provided which needs to be imported into the database. Please write a task which can import this messages into the database.
messages_sample.json
Shared on Dropbox

{
  "messages": [
    {
      "uid": "21",
      "sender": "Ernest Hemingway",
      "subject": "animals",
      "message": "This is a tale about nihilism. The story is about a combative nuclear engineer who hates animals. It starts in a ghost town on a world of forbidden magic. The story begins with a legal dispute and ends with a holiday celebration.",
      "time_sent": 1459239867
    },
    {
      "uid": "22",
      "sender": "Stephen King",
      "subject": "adoration",
      "message": "The story is about a fire fighter, a naive bowman, a greedy fisherman, and a clerk who is constantly opposed by a heroine. It takes place in a small city. The critical element of the story is an adoration.",
      "time_sent": 1459248747
    },
    {
      "uid": "23",
      "sender": "Virgina Woolf",
      "subject": "debt",
      "message": "The story is about an obedient midwife and a graceful scuba diver who is in debt to a fence. It takes place in a magical part of our universe. The story ends with a funeral.",
      "time_sent": 1456767867
    },
    {
      "uid": "24",
      "sender": "George Orwell",
      "subject": "chemist",
      "message": "This is a tale about degeneracy. The story is about a chemist. It takes place in a manufacturing city. The story begins with growth.",
      "time_sent": 1456744407
    },
    {
      "uid": "25",
      "sender": "James Joyce",
      "subject": "nuclear engineer",
      "message": "The story is about an ugly nuclear engineer. It starts in a manufacturing city in Africa. The future of warfare is a major part of this story.",
      "time_sent": 1456733427
    },
    {
      "uid": "26",
      "sender": "Jane Austen",
      "subject": "treasure-hunter",
      "message": "The story is about a treasure-hunter and a treasure-hunter who is constantly annoyed by a misguided duke. It takes place on a forest planet in a galaxy-spanning commonwealth. The critical element of the story is a door being opened",
      "time_sent": 1456730427
    }
  ]
}

API security

As dev
I want to have a basic security middleware for API
So that it is accessible only by authorized users

Description

Acceptance Criteria
Use a basic Http autorisation

  • tests

QA

API Design

As a dev
I want to expose API as a swagger
So that it is publicly available

Message API
The main task is to build an API for the messages. It should to be a REST based API with a JSON formatted payloads.
The API should support the following use-cases.

  • List messages
    Retrieve a paginateable list of all messages. Show if messages were read already.
  • List archived messages
    Retrieve a paginateable list of all archived messages. Show if messages were read already.
  • Show message
    Retrieve message by id, include read status and if message is achived.
  • Read message
    This action “reads” a message and marks it as read in database.
  • Archive message
    This action sets a message to archived.

Acceptance

  • swager file describe api
  • service serve a swager as a docs

Sub tasks
#5 Open API

Pagination strategy

Acceptance

  • strategy desides
  • peflected in api
  • doc with explanation provided

Implement pagination get

As REPLACEME
I want REPLACEME
So that REPLACEME

FILL_ME_IN

Description

Acceptance Criteria

  • tests

QA

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.