copied the code from the working repo
This commit is contained in:
15
mtucijobsweb/api/bot.ts
Normal file
15
mtucijobsweb/api/bot.ts
Normal file
@@ -0,0 +1,15 @@
|
||||
import { Bot } from '@/types/types';
|
||||
import axios from 'axios';
|
||||
|
||||
export const sendDataBot = async (dataBot: Bot) => {
|
||||
try {
|
||||
const response = await axios.post(
|
||||
`${process.env.NEXT_PUBLIC_BOT_URL}/api/resume/`,
|
||||
dataBot
|
||||
);
|
||||
return response;
|
||||
} catch (error) {
|
||||
console.error('Error post student:', error);
|
||||
throw error;
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user