Register
Submit a solution
The challenge is finished.

Challenge Overview

Challenge Objectives

  • Create a wrapper for Topcoder Challenge API (v5)

  • The wrapper is intended to be used as a public module for use in other applications

 

Project Background

  • Challenge API is a project that deals with all things related to challenges.

  • It essentially is a CRUD api

 

Technology Stack

  • Nodejs version 10

 

Code access

You are writing the wrapper and there is no initial code base to start off with.

 

Individual requirements

Create a wrapper for Topcoder Challenge API (v5) (Major Requirement)

  • We will be creating a Nodejs based wrapper for an existing API of Topcoder called Challenge API

  • Note that this wrapper will be for the version 5 of the challenge api (there is a version 3 and 4 of this api as well which is NOT in scope)

  • You can find the source code here. Please make sure you are on the “develop” branch

  • You can find the swagger specification for this api here. You will be using this as a reference when creating the wrapper.

  • Not all endpoints are in scope. The list of endpoints that are in scope will be shared in the contest forum.

 

Provide documentation for the wrapper (Major Requirement)

  • After creating the wrapper, you need to provide a documentation for it

  • The expectation from the documentation is any developer that installs this wrapper as a nodejs module in their application is able to follow the documentation and determine how to use the wrapper to make requests to the v5 challenge api

 

Provide tests for the wrapper (Minor Requirement)

  • Provide tests for the wrapper

  • You will use mocha and chai for testing

  • Use nock to mock the api requests. Do not make actual api calls.

  • This point alone is a major requirement - your tests will NOT test the challenge api. Your tests will only test if the wrapper works correctly or not. You are not expected to test if the challenge api itself works correctly.

  • You need to provide unit tests and end to end tests with a code coverage of 80% or more.

 

Deployment guide and validation document

There is no “deployment guide” needed for this wrapper. Instead, we are looking for a good documentation on how to install the wrapper as well as how to use it. Please refer to the submission api wrapper that we would like you to use as a reference.

 

Important Notes

  • Use async await pattern

  • Use standard as your linter. Ensure there are no lint errors in your submission.

  • Typescript is not allowed. No build or compilation of code is expected

  • Kindly use the submission api wrapper as reference when creating the challenge api wrapper. Check out the documentation of the submission api wrapper in particular - we are expecting the documentation to be on the same lines.

  • You will indeed support the three different methods of authorization - user jwt tokens (like the ones you get when you login to Topcoder), m2m tokens (the ones that are generated by other apps to communicate between each other) and direct jwt token (the one where the token is not generated but instead directly passed - it is either the user jwt token or m2m token, but it is not generated by the wrapper itself). Please check out the submission api wrapper for details on each of these.

  • You need to use the swagger specification as reference. If there is a discrepancy between the behaviour of the api v/s what is defined in swagger specification, kindly use the swagger specification as the source of truth (and let us know in the contest forum).

  • We already have an existing module that acts as the wrapper. However, that is not to our expectations and thus we are launching this contest. You cannot use that module in your submission and have to necessarily create a new one. That wrapper is also NOT for the v5 challenge api, which is the subject of this contest

  • The wrapper is not expected to validate that all the fields / attributes that a request needs are provided. It’s task is to only provide helper functions.



Final Submission Guidelines

Zip your solution and upload to Topcoder.

 

ELIGIBLE EVENTS:

2020 Topcoder(R) Open

Review style

Final Review

Community Review Board

Approval

User Sign-Off

ID: 30105167