aircall / aircall-everywhere Goto Github PK
View Code? Open in Web Editor NEWSDK to embed and communicate to Aircall phone in any web page
Home Page: https://aircall.github.io/aircall-everywhere
SDK to embed and communicate to Aircall phone in any web page
Home Page: https://aircall.github.io/aircall-everywhere
Using aircall-everywhere
npm module requires the user to transpile the code to es5 for uglifyjs plugin to work. Reference.
Currently I use the above suggested approach allowing my babel transpile to include aircall-everywhere
module like this.
rules: [
{
test: /\.js*$/,
exclude: /node_modules\/(?!(aircall-everywhere))/,
loader: 'babel-loader',
query: {
presets: ['env', 'react'],
"plugins": ["transform-object-rest-spread"]
}
},
Rest of my webpack config follows
It would be nice to transpile the code to es5 and then publish to npm.
Hi Aircall,
The send function dial_number
event accepts phone_number
as an argument. That defines the TO phone number.
But I have multiple phone numbers under my user and I want to vary the FROM phone number. It doesn't look like the send function would accept an argument to define a FROM phone number.
Can you please add this?
Hi,
I am trying to catch when operator cancels incoming call (clicks on the red button). The only event that triggers is incoming_call
at the beginning of the call. Event call_end_ringtone
is not working in this case... I tried all the available callbacks.
Thank you
Though the SDK works in local environment, when we push it to production,
Refused to frame 'https://phone.aircall.io/' because an ancestor violates the following Content Security Policy directive: "frame-ancestors 'self' http://localhost:* *.fusionamspro.com *.inzee.care *.fusionsd.com.au *.clevero.co *.driver360.org *.thescouts.com.au *.ubbitt.com ubbitt.com *.boxtal.com support.upowr.com crm.core.upowr.cloud enforceau.com.au *.avicrm.net *.aviseguros.com freshsales.io api.freshsales.io events.freshsales.io cdn.freshsales.io app.freshsales.io accounts.freshsales.io dnalegalmim.com *.dnalegalmim.com homepro.com *.homepro.com *.getheroes.run *.crisp.chat app.zeliq.com zeliq.com app.eambulanta.si *.peppercloud.com *.mypropertysuite.io ucrmweb.co integration.ucrmweb.co cedf.my.site.com *.leovida.com *.vivaservices.fr *.menageo.fr *.vipmanaging.com *.desibites.com *.odoo.com *.edesk.com *.90tech.fr *.scaffold.digital *.dnalegalmim.com openinfrase.my.site.com *.onlive.site *.avicrm.es crm.foodforjoe.es *.abuelosplus.es *.retraiteplus.ch *.seniorhomeplus.uk *.casas-senior.pt *.placessenior.com *.casadiriposopiu.it *.uniresi.es app.frontapp.com *.kalendes.com bolt.buscoresi.com *.aurasoft.fr *.cloudfront.net *.aircall.io bolt.buscoresi.com *.alan.com alan.com yonivers.aurasoft.fr aurasoft.fr *.freshdesk.com *.myfreshworks.com *.myfreshworks.dev *.freshpo.com *.freshpori.com *.freshchat.com *.juno.legal *.juno.works aircall.github.io *.freshworks.com *.tangerineglobal.com *.microsoft.com *.novatedleaseaustralia.com.au *.formaliteauto.com *.retraiteplus.be *.nocrm.io *.avaibook.com *.amazonaws.com *.anwalt.de *.apollo.io *.bloobirds.com *.casinobarcelona.es *.flatfair.co.uk *.doctoralia.es *.doktortakvimi.com *.clivi.com.mx *.documentforce.com *.drivania.com *.elabogado.com *.feit.com *.firstluggage.com *.foodsby.com *.futuresimple.com *.geomapper.io *.gibobs.com *.golftec.com *.google.com *.greenpan.com *.happyfox.com *.heymarket.com *.homevest.io *.hopkins.systems *.hubspoteditor.com *.hubspot.com *.inspiringvacations.com *.intercom.com *.jameda.de *.jumpcloud.com *.kactus.com *.lemlist.com *.linear.app *.linkedin.com *.looker.com *.lussostone.com *.live.com *.macartevacances.fr *.medicalcard.io *.missiveapp.com *.niceincontact.com *.office.net *.okta-emea.com *.okta.com *.outreach.io *.prenuvo.com *.reamaze.com *.rebag.com *.rezdy.com *.simplebo.net *.shopware.com *.soldo.com *.sortlist.com *.sportscope.com *.steeple.fr *.theguarantors.com *.treble.ai *.zehnder.fr *.zendesk.com *.zendesk.es *.adyen.help *.asana.com *.blablacar.com *.callexcell.be *.com.slack *.deporvillage.com *.doctoranytime.gr *.lusha.com *.medelse.com *.merxu.com *.onepilot.co *.planhat.com *.poppy.be *.retraiteplus.fr *.stikets.info *.swipoo.com *.tailorbrands.com *.tiierisch.de *.zdusercontent.com *.visualforce.com *.salesforce-experience.com *.salesforce.com *.force.com *.doctoralia.com.br *.doctoralia.es *.hapily.com *.myrightmove.com.au *.mobilemod.com mobilemod.com *.docs.google.com *.derecho.com *.csp.withgoogle.com *.ssl.gstatic.com *.apis.google.com *.script.google.com *.googleusercontent.com *.bubble.io bubble.io *.frontapp.com *.freshdev.io https://fairsquaremedicare.com/ *.app.bedrockmedicare.com".
Any idea to fix this?
exists any way to end the current outcoming call in the phone from js code( as event "dial_number")?
In a Vite 4.0.1 project, I encountered the following error.
My code (useAircallDialer.tsx)
After a few hours, the only solution we found was to add to your Vite configuration :
export default defineConfig({
build: {
commonjsOptions: { include: [] },
},
optimizeDeps: {
disabled: false,
},
}
I am writing this here to prevent
How to auto-login into aircall phone window after the authentication with aircall account (Oauth)?
In our app, firstly authenticate the aircall account (using Oauth integration) and after the authentication process, aircall redirects to our website/app and on this redirect page, we display aircall phone window, but the aircall phone is not auto-login first time. We again login into this window.
Can you provide a solution for this so we can use a single login?
on("outgoing_call"
, callback) is not firing if calling invalid number (example dial without country code)
Can anyone check this issue? Thanks!
Hi, so I think I found another issue but I'm not sure how to put it.
I was trying to observe the Call Object data by adding AJAX to the List of Call API using the call_id from callInfos at the call_ended event.
(I added console.log to show data from ajax)
So, I performed the call (and answered by the other side) then end the call from Aircall Everywhere SDK UI, the call status from API is equals to 'done' (which is expected).
However, if I added Comment / Note from the Aircall Everywhere SDK UI and End the call from the agent side, the call status from API will be 'answered' with empty comment object.
My query for this case is: shouldn't the call status = 'done' and the comment object is populated right when the call_end is called?
Thanks!
Hi
I webpacked sdk file ,i want to call event call answer or ring end ,end call from my js file based on click event .How to implement that.
This would seem to be a basic functionality for any telephony company.
Just trying to get aircall-everywhere integrated with our app and have been unable to get the 'incoming_call' event to fire. When running in debug mode this doesn't appear to even produce an event in the way other events do.
Even the Aircall Everywhere demo page seems to have this issue as well - no event ever appears in the events section of the page, and if the phone is collapsed, it never auto-reappears as the demo event listener calls for.
Is this something I'm doing wrong, or a known issue with the client?
When a user try to reach us and we don't answer the event appears to not be triggered.
Is this project still in active developement ?
In the readme there are some hope for new events :)
Is it possible to have the link for the mp3 from an event ?
Thanks alot for your feedback
The AircallPhone
class adds event listeners to the window object (this.w
) upon instantiation here.
However, as far as I can tell there is no way to clean up this listener (and any other side effect that instantiation may cause). Thus, once you load the aircall iframe in your app there is no true way to do a full cleanup once the call flow is over.
It would be great to have some sort of .destroy()
method to clean up the client.
Thank you in advance for taking a look!
I just added the library to my React app and after logging in, I'm receiving a lot of errors related to permissions and security.
The code related to Aircall
import { Fab, Paper, SvgIcon } from "@mui/material"
import LoginIcon from "@mui/icons-material/Login"
import { useTranslation } from "next-i18next"
import { styled } from "@mui/system"
import AircallPhone from "aircall-everywhere"
import useIntegrations from "../../hooks/useIntegrations"
import { useState } from "react"
import AircallPic from "../../../public/images/third_party_logos/aircall.svg"
import AircallSVG from "../customSVG/AircallSVG"
import AircallIcon from "../customSVG/AircallSVG"
const StyledFab = styled(Fab)(({ theme }) => ({
position: "fixed",
top: "80px",
right: "20px",
backgroundColor: "white"
}))
const AircallContainer = styled(Paper)(({ theme }) => ({
position: "fixed",
top: "130px",
right: "50px",
zIndex: 2000,
"& #phone": {
iframe: {
border: 0
}
}
}))
export default function AircallIntegration() {
const { t } = useTranslation()
const { included: aircall } = useIntegrations("aircall")
const { included: hubspot } = useIntegrations("hubspot")
const [login, setLogin] = useState(false)
const phone = new AircallPhone({
domToLoadPhone: "#phone",
onLogin: settings => {
console.log(settings)
setLogin(true)
},
onLogout: () => {
setLogin(false)
},
//integrationToLoad: hubspot ? "hubspot" : null,
size: "big",
debug: process.env.REACT_APP_ENVIRONMENT === "development"
})
//if (true) return null
if (!aircall) return null
return (
<>
<StyledFab size="large">
<AircallIcon size="large" />
</StyledFab>
<AircallContainer elevation={3}>
<div id="phone" />
</AircallContainer>
</>
)
}
I'm currently trying the generic integration with an iframe in our CMS. I'm trying to place a call, but, if the number shows up in the dialer, the call is not placed and I get an error.
I'm posting a message to the iframe with the parameters using the eventName dial_number
and the data { phone_number: [my phone number] }
as in the docs, and it seems to work well since I receive a message form the phone with apm_phone_dial_number_response
with a value {success : true}
.
But the call does not start and I receive an error { "code": "no_answer", "message": "No answer from the phone. Check if the phone is logged in" }
. I'm logged in and I can place a manual call so I don't think it is a problem of being not logged in...
What could be the reason ? What could be the workaround ?
So I found the Aircall Everywhere SDK from Aircall API Documentation then I went to the demo page to check them.
However, I found that the comment_saved and call_end_ringtone event are not triggering during / after the outbound call.
Can anyone check this issue? Thanks!
We have integrated the phone and sometime the page is refreshed auto, we haven't idea why.
could be that this happen for an event with the phone ?
this is a problem serious for us because this happens while our agents are in a call, so the call finish.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.