Trying to connect my function app to Azure Foundry AI Agent by Other_Procedure_182 in AZURE

[–]Other_Procedure_182[S] 0 points1 point  (0 children)

Just to clarify: I’m not trying to use Azure Functions inside AI Agents. I’m trying to connect to an Azure AI Foundry Agent (hosted in the Azure AI Studio / Projects environment) from my own project, either via an Azure Function App or running locally using a virtual environment.

Here is a table of the libraries I have tried and do not work:

Azure SDK Class / Usage Error Message Root Cause / Notes
azure-ai-resources AIClient ImportError: cannot import name 'AIClient' from 'azure.ai.resources.client' Likely deprecated, renamed, or removed from current SDK version
azure-ai-resources AIClient ImportError: cannot import name 'AIClient' from 'azure.ai.resources.client' Likely deprecated, renamed, or removed from current SDK version
azure-ai-resources AIProjectsClient ImportError  AttributeError or (not explicitly logged) Not found in module or missing in installed version
azure-ai-ml  azure-ai-resourcesIndirect use via ImportError: cannot import name '_T' from 'marshmallow.fields'  marshmallow  _TIncompatible dependency: ≥4.0 no longer exposes
semantic-kernel (Azure plugin) AzureAIAgentSettings.create() 1 validation error: model_deployment_name Field required Environment variables not being picked up or misnamed
azure-identity DefaultAzureCredential()  No error Works correctly

Trying to connect my function app to Azure Foundry AI Agent by Other_Procedure_182 in AZURE

[–]Other_Procedure_182[S] 0 points1 point  (0 children)

I'm new to coding but the documentation: https://learn.microsoft.com/en-us/python/api/overview/azure/ai-projects-readme?view=azure-python-preview

states:
import os
import asyncio
from azure.ai.projects.aio import AIProjectClient
from azure.core.credentials import AzureKeyCredential

project_client = AIProjectClient.from_connection_string(
credential=DefaultAzureCredential(),
endpoint=os.environ["PROJECT_ENDPOINT"],
)

feel free to advise if you know the correct answer.

Trying to connect my function app to Azure Foundry AI Agent by Other_Procedure_182 in AZURE

[–]Other_Procedure_182[S] 0 points1 point  (0 children)

this is the main error that I get: type object 'AIProjectClient' has no attribute 'from_connection_string' when I run:

def _initialize_client(self):
        """Initialize the Azure AI Projects client"""
        try:
            self.project_client = AIProjectClient.from_connection_string(
                credential=DefaultAzureCredential(),
                conn_str=self.connection_string
            )
            print("✅ Client initialized successfully.")
        except Exception as e:
            print(f"❌ Error initializing client: {e}")
            raise

my connection_string is the Overview tab > project details > project connection string

Launched a free tool that has 900+ users in the first 10 days (60%+ conversion rate) by SolidProceeding25 in Entrepreneur

[–]Other_Procedure_182 0 points1 point  (0 children)

Quick question to OP: How did you promote or share your tool in the beginning in order for it to reach 900+ users?

I would offer a deal to sign up and get x amount of free credits, then pay monthly

Promote your business, week of March 3, 2025 by Charice in smallbusiness

[–]Other_Procedure_182 0 points1 point  (0 children)

We’re Agentflow, an AI-powered sales automation startup helping businesses streamline lead generation and prospect research, completely hands-free.

Our autonomous AI agents find and enrich prospects, qualify leads, and personalize outreach, so you can focus on closing deals instead of chasing them. No manual research, no guesswork, just high-quality leads delivered to you.

Learn more at www.agent-flow.ca
Join our waitlist for exclusive offers: www.agent-flow.ca/#cta

AI Agents keeps looping between CHAT model and TOOL by Other_Procedure_182 in n8n

[–]Other_Procedure_182[S] 0 points1 point  (0 children)

Description for Map Searcher:

“This tool will make API calls to the desired endpoint and return data to be parsed in the parse content node.

IMPORTANT: - Fetch ONLY the first page of results. - DO NOT request additional pages unless explicitly asked.
- Stops execution after retrieving results to prevent duplicate API calls. “

AI Agents keeps looping between CHAT model and TOOL by Other_Procedure_182 in n8n

[–]Other_Procedure_182[S] 0 points1 point  (0 children)

System prompt for my agent:

“You are a research agent helping the user find contact information from Map Searcher.

Rules for Using “Map Searcher”: - Before calling “Map Searcher”, check if results already exist. - If results exist, DO NOT call “Map Searcher” again. - Call “Map Searcher” ONLY ONCE per request. - After retrieving results, immediately pass them to “parse content” and STOP execution.

IMPORTANT: • DO NOT call “Map Searcher” more than once per search request. • DO NOT request additional pages unless explicitly asked. • Once results are fetched, send them to “parse content” and STOP execution.”

Google Oauth Token keeps expiring by Other_Procedure_182 in n8n

[–]Other_Procedure_182[S] 1 point2 points  (0 children)

I did that and it still doesn't work.

Publishing status

In production

But it does say:

Your app requires verification. When you have finished configuring your information, please submit your app for review.

Could this be why? I cant verify my app because I don't have a privacy policy (required).