Challenge Overview

Challenge Objectives

  • Create a wrapper for Topcoder Challenge API (v4)

  • 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 (v4) (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 4 of the challenge api (there is a version 3 of this api as well which is NOT in scope. Also, there is a version 5 of this api which is still a work in progress and also NOT in scope)

  • You can find the source code here. Please make sure you are on the “dev” 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 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 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

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

 

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.

  • Kindly note that the challenge api source code is in Java. But the wrapper that you are writing will be in Nodejs. 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



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

SHARE:

ID: 30103664