# Customer info from remote system

**URL:** https://community.zammad.org/t/customer-info-from-remote-system/12649
**Category:** Development
**Created:** [November 16, 2023, 8:19am UTC](https://community.zammad.org/t/customer-info-from-remote-system/12649 "2023-11-16T08:19:10Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![rolfschmidt](https://community.zammad.org/user_avatar/community.zammad.org/rolfschmidt/32/3368_2.png) [@rolfschmidt](https://community.zammad.org/u/rolfschmidt)
#### Post date: [November 30, 2023, 10:54am UTC](https://community.zammad.org/t/customer-info-from-remote-system/12649/2 "2023-11-30T10:54:15Z")

</div>

You could add a new sidebar like this:

**app/assets/javascripts/app/controllers/ticket\_zoom/sidebar\_custom.coffee**

```plaintext
class SidebarCustom extends App.Controller
  sidebarItem: =>
    @item = {
      name: 'Custom'
      badgeIcon: 'templates'
      sidebarHead: __('Custom')
      sidebarCallback: @showCustom
    }
    @item

  shown: ->
    @showCustom(undefined, true)

  showCustom: (el, load = false) =>
    @elSidebar = el if el

    @startLoading()
    return if !load

    console.log('sidebar data', @ticket)

    @ajax(
      id: "Custom_#{@ticket.id}"
      type: 'GET'
      url: "#{@apiPath}/tickets/#{@ticket.id}"
      processData: true
      success: (data, status, xhr) =>
        console.log('endpoint data ', data)
        @stopLoading()
        @elSidebar.html('<p>Custom information for customer id ' + @ticket.customer_id + '</p>')
    )

App.Config.set('310-Custom', SidebarCustom, 'TicketZoomSidebar')

```

You might get problems when you requesting remote urls because of the CSP I guess.

[https://github.com/zammad/zammad/blob/93cbf90f042778d013431f5131f1e1a917a7c14b/config/initializers/content\_security\_policy.rb](https://github.com/zammad/zammad/blob/93cbf90f042778d013431f5131f1e1a917a7c14b/config/initializers/content_security_policy.rb)

not sure how to edit it properly atm. You could also think about to add a new controller and proxy your data through that alternatively.

For packages there are some small tutorials [here](https://community.zammad.org/t/packages-tutorial/12079)

---

_[View the full topic](https://community.zammad.org/t/customer-info-from-remote-system/12649)._
