Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

245
Views
Cómo agregar URL como parámetro en Asp.net

Estoy en una situación en la que necesito pasar la URL como parámetro de javascript a Controller. Pero cuando paso la URL como parámetro, aparece un error.

 async sendSmsNotification() { var url = new URL(`https://chats.landbot.io`); var PlanId = "123"; await NotificationService.sendNotification(PlanId, url); }

 export async function sendNotification(PlanId: string, url: string) { let url = HttpClient.buildUrl(`api/sendNotification/${PlanId}/${url}`); return await HttpClient.get(url); }

A continuación se muestra el método de acción donde espero un enlace de URL

 [HttpGet("Notification/{PlanId}/{url}")] [ValidateModelState] public async Task<IActionResult> SendNotification(Guid PlanId, string url) { var Plan = await _PlanRepository.GetPlan(PlanId, SecurityToken); try { return NoContent(); } catch (ArgumentException ex) { return BadRequest(ex.Message); } }

estoy recibiendo este error

 httpClient.ts:98 GET https://localhost:44386/api/Notification/c2776efe-49aa-46ff-a7f8 404

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!