Node.js Conditional Logic Integration
Budget / Salary$50–100
TypeFreelance project
LocationRemote
Posted21 minutes ago
I have a running Node.js service at AWS that already consumes an external API. I now need a small, precise change: after the API response arrives, I want to inspect a single field called ExpectNumeric.
• If ExpectNumeric is true, run condition A by calling an existing function I will point you to.
• If ExpectNumeric is false, fall back to condition B, which triggers a different helper already present in the codebase.
Nothing else in the flow should change—no retries, no new endpoints, just the added if statement (or a clean ternary, whichever keeps the codebase style consistent). The logic sits inside an async function that currently parses the response, so familiarity with async/await patterns is important.
Deliverable
– A single updated JS file (or a pull request) showing the conditional check and the two function calls wired correctly, along with a brief comment explaining the change.
The project is straightforward, but clarity and adherence to our existing lint rules matter. Let me know if anything about the current structure is unclear and I’ll share the relevant snippet right away.
• If ExpectNumeric is true, run condition A by calling an existing function I will point you to.
• If ExpectNumeric is false, fall back to condition B, which triggers a different helper already present in the codebase.
Nothing else in the flow should change—no retries, no new endpoints, just the added if statement (or a clean ternary, whichever keeps the codebase style consistent). The logic sits inside an async function that currently parses the response, so familiarity with async/await patterns is important.
Deliverable
– A single updated JS file (or a pull request) showing the conditional check and the two function calls wired correctly, along with a brief comment explaining the change.
The project is straightforward, but clarity and adherence to our existing lint rules matter. Let me know if anything about the current structure is unclear and I’ll share the relevant snippet right away.
Apply on Freelancer →
Project sourced from Freelancer.com. Applications happen directly on the original platform — we never collect your data.