web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Copilot Studio / Convert custom website...
Copilot Studio
Suggested Answer

Convert custom website endpoint to Direct API endpoint

(0) ShareShare
ReportReport
Posted on by 2
Hi All,

We trying to consume custom copilot through API, unfortunately we are not able to see the direct option. So we are trying to take the custom website endpoint but getting the 404 error

we are using the below code 
 
import requests
 
# Endpoint URL
url = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
 
# Headers (if required)
headers = {
    "Authorization": "Bearer xxxxxxxxx",  # Replace with your actual token
    "Content-Type": "application/json"
}
 
# Payload: Question or Input
payload = {
    "question": "What are the store hours today?"  # Replace with your actual question or input
}
 
# Send the POST request
response = requests.post(url, headers=headers, json=payload)
 
# Handle the response
if response.status_code == 200:
    print("Response:", response.json())  # Assuming JSON response
else:
    print("Failed with status code:", response.status_code)
    print("Response:", response.text)
Categories:
I have the same question (0)
  • Suggested answer
    Artur Stepniak Profile Picture
    1,539 Super User 2025 Season 2 on at
    Hello,
     
    what do you mean by custom copilot? Is it something that was built by using Bot Framework SDK or what? Or was it built in Copilot Studio? If the second option, then it's not possible to consume - you don't have access to the deployment. If you'd like to have that kind of functionality, then you can use Azure AI Foundry (former Azure AI Studio) and customize it as you wish.
     
    In case of any other questions, let me know. If the answer helped you, mark it, so that others can benefit from it.
     
    Best regards,
     
    Artur Stepniak
  • fchopo Profile Picture
    8,003 Moderator on at
    Hello,
    I did that several months ago and you should use Bot Framework SDK and use Direct Line API v3.0: https://learn.microsoft.com/en-us/azure/bot-service/rest-api/bot-framework-rest-direct-line-3-0-concepts?view=azure-bot-service-4.0
     
     
     
    Hope that helps!
    Ferran
  • KS-12120731-0 Profile Picture
    2 on at
    Hi,

    The plan is like we don't want to use any azure services, so is there any alternative method to fetch the Custom copilot studio end point directly into python code. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Copilot Studio

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 261 Super User 2025 Season 2

#2
Romain The Low-Code Bearded Bear Profile Picture

Romain The Low-Code... 198 Super User 2025 Season 2

#3
S-Venkadesh Profile Picture

S-Venkadesh 93 Moderator

Last 30 days Overall leaderboard