CtrlK
CommunityDocumentationLog inGet started
Tessl Logo

tessl/npm-rest

tessl install tessl/npm-rest@2.0.0

RESTful HTTP client library with composable interceptor architecture for Node.js and browsers

Agent Success

Agent success rate when using this tile

76%

Improvement

Agent success rate improvement when using this tile compared to baseline

1.29x

Baseline

Agent success rate without this tile

59%

rubric.jsonevals/scenario-2/

{
  "context": "This evaluation assesses how effectively the engineer uses rest.js's interceptor architecture to implement request and response logging. The focus is on proper usage of the client.wrap() API, interceptor lifecycle phases (request and response), and the interceptor return value patterns.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Uses client.wrap()",
      "description": "The implementation uses the client.wrap() method to apply an interceptor to the HTTP client, rather than attempting to manually wrap or modify requests",
      "max_score": 20
    },
    {
      "name": "Implements request phase",
      "description": "The interceptor defines a 'request' phase function that captures request metadata (method, path, timestamp) before the request is sent",
      "max_score": 20
    },
    {
      "name": "Implements response phase",
      "description": "The interceptor defines a 'response' phase function that captures response metadata (status code, duration) after the response is received",
      "max_score": 20
    },
    {
      "name": "Returns request in request phase",
      "description": "The request phase function properly returns the request object (or a promise resolving to it) to maintain the interceptor chain",
      "max_score": 15
    },
    {
      "name": "Returns response in response phase",
      "description": "The response phase function properly returns the response object (or a promise resolving to it) to maintain the interceptor chain",
      "max_score": 15
    },
    {
      "name": "Configurable via init",
      "description": "The interceptor uses the 'init' phase or configuration object to allow customization of log output destination (array vs console)",
      "max_score": 10
    }
  ]
}

Version

Workspace
tessl
Visibility
Public
Created
Last updated
Describes
npmpkg:npm/rest@2.0.x
tile.json