• J. Scott Cromie
  • NEWBIE
  • 0 Points
  • Member since 2015


  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 1
    Likes Given
  • 5
    Questions
  • 7
    Replies
Hi All,

I'm trying to pull all the metadata I can from a heavily customized org.  I tried using a package.xml file, but it seemed to be quite unwieldy.  And then, I happened upon force:source:retrieve in sfdx!  It worked with a small subset of the Metadata types relating to custom objects  

sfdx force:source:retrieve -m CustomObject,ActionOverride,HistoryRetentionPolicy,RecordType,SearchLayouts,SharingRecalculation

so I thought "Great!  Let's try it with everything!"

sfdx force:source:retrieve -m AccountRelationshipShareRule,ActionLinkGroupTemplate,AnalyticSnapshot,AnimationRule,ArticleType,ApexClass,ApexComponent,ApexPage,ApexTestSuite,ApexTrigger,AppMenu,ApprovalProcess,AssignmentRules,Audience,AuraDefinitionBundle,AuthProvider,AutoResponseRules,Bot,BotVersion,BrandingSet,CallCenter,CampaignInfluenceModel,CaseSubjectParticle,Certificate,ChatterExtension,CleanDataService,CMSConnectSource,Community,CommunityTemplateDefinition,CommunityThemeDefinition,ConnectedApp,ContentAsset,CorsWhitelistOrigin,CspTrustedSite,CustomApplication,CustomApplicationComponent,CustomFeedFilter,CustomHelpMenuSection,CustomLabels,CustomNotificationType,CustomObject,ActionOverride,BusinessProcess,CompactLayout,CustomField,FieldSet,HistoryRetentionPolicy,Index,ListView,NamedFilter,RecordType,SearchLayouts,SharingReason,SharingRecalculation,ValidationRule,WebLink,CustomObjectTranslation,CustomPageWebLink,CustomPermission,CustomSite,CustomTab,CustomValue,Dashboard,DataCategoryGroup,DelegateGroup,Document,DuplicateRule,EclairGeoData,EmailServicesFunction,EmailTemplate,EmbeddedServiceBranding,EmbeddedServiceConfig,EmbeddedServiceFieldService,EmbeddedServiceFlowConfig,EmbeddedServiceLiveAgent,EntitlementProcess,EntitlementTemplate,EscalationRules,EventDelivery,EventSubscription,ExternalDataSource,ExternalServiceRegistration,FeatureParameterBoolean,FeatureParameterDate,FeatureParameterInteger,FlexiPage,Flow,FlowCategory,FlowDefinition,Folder,GlobalPicklist,GlobalPicklistValue,GlobalValueSet,GlobalValueSetTranslation,Group,HomePageComponent,HomePageLayout,InstalledPackage,KeywordList,Layout,Letterhead,LightningBolt,LightningComponentBundle,LightningExperienceTheme,LiveChatAgentConfig,LiveChatButton,LiveChatDeployment,LiveChatSensitiveDataRule,ManagedTopics,MatchingRule,Metadata,MetadataWithContent,MilestoneType,ModerationRule,NamedCredential,Network,NetworkBranding,Package,PathAssistant,PermissionSet,PlatformCachePartition,PlatformEventChannel,Portal,PostTemplate,PresenceDeclineReason,PresenceUserConfig,Profile,ProfileActionOverride,ProfilePasswordPolicy,Queue,QueueRoutingConfig,QuickAction,RecommendationStrategy,RecordActionDeployment,RemoteSiteSetting,Report,ReportType,Role,RoleOrTerritory,SamlSsoConfig,Scontrol,ServiceChannel,ServicePresenceStatus,Settings,SharedTo,SharingBaseRule,SharingRules,SharingSet,SiteDotCom,Skill,StandardValueSet,StandardValueSetTranslation,StaticResource,SynonymDictionary,Territory,Territory2,Territory2Model,Territory2Rule,Territory2Type,TimeSheetTemplate,TopicsForObjects,TransactionSecurityPolicy,Translations,UserCriteria,UserInterfaceSettings,WaveApplication,WaveDataflow,WaveDashboard,WaveDataset,WaveLens,WaveTemplateBundle,WaveXmd,Workflow,WorkSkillRouting,WorkSkillRoutingAttribute

I got an UNKNOWN_ERROR with the error code 
error 1351326929-14746 (571045392)

Not sure if there's some limit I'm hitting, but I'd like to know if anyone else has seen this or has attempted to grab everything to seed a bitbucket repository from a configured (and I'm talking YEARS) org.

Thanks,

Scott
Hi everyone!

Would anyone out there have a baseline package.xml file that would allow me to seed a bitbucket repo?  I know I could just use the default one out of the box, but that only has code metadata types and I'm looking for as much metadata as I can get.  This org that I'm working in now is heavily cutomized.

I am indeed looking for a timesaver/shortcut, so if there's nothing available I'll go ahead and put one together and post it.

Thanks in advance all!

Scott
Hi folks,

I am trying to access and send the body of an attachment to a node.js server.  In essence what I want to do is get the data, pop it into a data URL (i.e. <img width="240" height="160" alt="scromie" src="data:image/jpeg;base64,/f39/QAQSkZJRgABAgAAAQABAAD9/QBDAAUDBAQEAwUEBAQFBQUGBwwIBwcHBw8KCwkMEQ8SEhEPERATFhwXExQaFRARGCEYGhwdHx8fExciJCIeJBweHx79/QBDAQUFBQcGBw4ICA4eFBEUHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh79....(data continues))">

I have worked out receiving the attachment body through the jsForce library's request module, like so:
 
var conn = result;
      var attBlob = conn.sobject('Attachment').record(req.query.attachId).blob('Body');
      var server = conn.instanceUrl;
      var resource = 'services/data/v37.0/sobjects/Attachment/' + req.query.attachId + '/Body';
      var resourceURL = server + resource;
      var options = { method: 'GET',
                      url: resourceURL,
                      headers:
                      {
                        authorization: 'Bearer \'' + conn.accessToken + '\''
                      }
                    };
      var attData = conn.request(options);
At the end of this, I get what I believe to be the binary data for the attachment: 
 
'����\u0000\u0010JFIF\u0000\u0001\u0002\u0000\u0000\u0001\u0000\u0001\u0000\u0000��\u0000C\u0000\u0005\u0003\u0004\u0004\u0004\u0003\u0005\u0004\u0004\u0004\u0005\u0005\u0005\u0006\u0007\f\b\u0007\u0007\u0007\u0007\u000f\n\u000b\t\f\u0011\u000f\u0012\u0012\u0011\u000f\u0011\u0010\u0013\u0016\u001c\u0017\u0013\u0014\u001a\u0015\u0010\u0011\u0018!\u0018\u001a\u001c\u001d\u001f\u001f\u001f\u0013\u0017"$"\u001e$\u001c\u001e\u001f\u001e��\u0000C\u0001\u0005\u0005\u0005\u0007\u0006\u0007\u000e\b\b\u000e\u001e\u0014\u0011\u0014\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e��\u0000\u0011\b\u0000�\u0000�\u0003\u0001"\u0000\u0002\u0011\u0001\u0003\u0011\u0001��\u0000\u001f\u0000\u0000\u0001\u0005\u0001\u0001\u0001\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b��\u0000�\u0010\u0000\u0002\u0001\u0003\u0003\u0002\u0004\u0003\u0005\u0005\u0004\u0004\u0000\u0000\u0001}\u0001\u0002\u0003\u0000\u0004\u0011\u0005\u0012!1A\u0006\u0013Qa\u0007"q\u00142���\b#B��\u0015R��$3br�\t\n\u0016\u0017\u0018\u0019\u001a%&\'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz���������������������������������������������������������������������������\u0000\u001f\u0001\u0000\u0003\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b��\u0000�\u0011\u0000\u0002\u0001\u0002\u0004\u0004\u0003\u0004\u0007\u0005\u0004\u0004\u0000\u0001\u0002w\u0000\u0001\u0002\u0003\u0011\u0004\u0005!1\u0006\u0012AQ\u0007aq\u0013"2�\b\u0014B����\t#3R�\u0015br�\n\u0016$4�%�\u0017\u0018\u0019\u001a&\'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz��������������������������������������������������������������������������\u0000\f\u0003\u0001\u0000\u0002\u0011\u0003\u0011\u0000?\u0000�\'�Y�\\�j\u0002��v�\u0001��\u0011��\u0004`�r�i[��)\u0017֭\bz�V�SA�N_��C�\u0011\u0014�\\�c5\rɽ�O��%�X�VB�?\f`�u����}���X�ټ�ɕa#(\u0011�l� ��\u0011���5�=\u0014ŏ��=�&��~\u001aӥh�5�8�V\nPɒ\u000f��|����Ś����݄n��v.=0\u0000��>�g�1,[�ߟ���t,:KS7&�h��.hp�=�����+m�T�V�\u0019�Q��\u0000\u001at�-�����pf\u000b$[��x7s��^==���I�\u0014\u0004\u001d���]Z�a�q��CЌv�#J\u0002�ϡ����\u0015��G=��o&�`(p\u0006z�"�]\u000b��\u0007�\u0016C�jv�f<o\bܮzdW��\u0013gv�`�U-��ͺ�PL�\u0019�0\fF�3��:%���Q�G�SG���)�0��V��O\u0012h�o\u0015��4qŝ��ʶy�ֽO�\u0019��J�(��\u00013\u001c�F[,:����\u001eQ�Ӝ�\tF[\u0014�\u001f\u00195疿\u0016�\u0019u��D��\u0019\b\t4q��\'\u0018e ~��F�X� Yb9F\u0000���r�CԮ\u0014\u0007��+\u0001QF��7F��Pi&b\u0005\'\u0011&9�\u0007#4л�P)�U�z���1ȻNj�l�A �F)�\u0003��\u0015\u0013Z�\u0006D�\u000fE:s���e\u001c�x��8\u0015\\\u0003�z1\u0015��M�h�*)\u001c\u0015\u0015\u001c2\u000e\u0005K+es��\u0011�u\u0006�k�!�|?`�z���\u0014}�c�\u0017�s?\u0010<qg��q\u001cJ\'�pv�\u001f\u0000{�+�u�cR�\u0016����\u000b3}���j�Rmݎ�������{\u0013��0�\n��M.\u000b��\u0000tv��^t�NŦ�&V?19��j兤��\u001eEWR3�p?\u001a��G�,\u001d�!\u0017�G���Q��0mjT"�(�\f\t���\u0014��X�\u001321���\u001b {�}��=�n�X�1�F\u0007�Z�T76Jb�H\\�Q� ��G:e�9ng���u�\ncq����e�[=��UĐ7̎?�n�XI\u0014�9l�XG\u001b�9Q�\u001e�JM>T���Y!\u0007��\u001f��M2\\\u001b1�[�;��6�\u001f&O�Zٺ��\u0018��7G���+>�\u000f.]��#=*��.\r\u0015�H�\u0010�E^�p.\u0010"g\u0007��\u001f�U州&\u0012�*\t�&�j�Y�=�s��-���\u0012�dvd���\u00108�I�{��V9�Ӯ[φS堖B\u0000�\u001d@�\u0015�Qe�\u000b\b��+�q�}���K4aNT��}�f�@����K��ӭ�e��1��8�̹\u001d+�~\u000ex�T�":v�:JbA��̌��\'��K(2+4�f�v(\u0004 �S����\r\u0018�"�1d�۸���\u00188�8\u0001\rT�yk��W\u00053�͢Ӱɓ<�NG\f9�\u0015���r�\u001c�O+\u0002��6♀\u00051\u0010Ƅv��\u0014�0��L�Sr@¨�O�l�3���\u0000�n��VЂ��M��Z$4��\u001b�.��ui�/��g9\u0003�\u001e߅K�Y�w�(\u001b\u0014e��Ui�Q�j��v�\u001d\u0005_�Q$!\u0015�\u0018P_�N\u0000����hZZ���K1�@8\u0018��]7�|(u���u�\u0006�=ϵd��\u001c�C\u0018\u0000g����?ҽ��6��Y�\u00111\r�����:��i\u0011�\u001f\u000e��\u0002����\u0019]�-]����O�=��4Ls�\u00075���\u0011\u0007�\u0001�8�[�z\f\u0002\u000e+\u0017#��V<���.�q\u0000H�L\f\u0002�\u0003��\\���k�\u000b�n4���\f\u000eT�\u0006ϵ}\b���<\u001a�h#�\u001a��d⏓O��ئ�>ŏ5\u000f�nAdz)��zVe��-JL!�g�\u000eF����^����2��c+�8�C\fH0#E\u001e¯��n�g�����V�w�\u001at�\u0010��?�T�����Zm:�����1_��ZF�t{j��8\u0018��C�zSDPZD\u0007�\\�s%QL�,葂L�iC��x��֬��\u0011�Y\u0004���F\r};�O��|��\u0004k\u0011n�W\u0015�׉���� ��U���\u0007$0�I6�:q��s��{V��������e\u001c}\u0018w���\u0013�8�E�E}\u0018U�|�"��q�\u001e����,\u0017�˵A\f>^�H����|\u0017Ԯ,���Wa\u0014��\u0016p7\noDqԂl����RB2y\u0014Z(� �p\b�59@��K��{X�O�TL�J�^I\u0015\u0011\u0019\u00157*�BM�\u0014R:w��\t(\u0013��7L��q�T\\�I\u0014@\t�y\u0015��\u0017�\t���\u0000d��b@T\u0001�׵<x�\u0015��o\f~\'i\u0018<�<`�-T7*;�$��"aUT�3�9�Kp�\u0003kn2�����VfUf@_{�\u0000��7\n��F��7\u0018\u001dk��[S��{j&�@q�Xs��_P�V�[�p����\u0007�\u0015�?\u0002�k�����\u0016�#?!a�k��5v�V�\u001e��������W6m�8\u0001zV���\u000e\t�Q��@�|��S\b�C������u�\u001d��\u0006�\u0017��\u00122k#�/��ж�#s�zS��\u00136��v\u001c5#J\u0017�T"ʎ8�j;��\u0018\u0007\u0014\\J���wI�1��D���\u001c��s�$�8\'��mn���P�{;\t�@���Ҿe����\u000e�o|���U���k�\t�4L\u00063��?�+Ow�ٺU;�l��j����>&\u0017�Ϛ��b�L\u0003���\u000f����1�\u0000#\u001d��Y�n\b�\b���\u0015�:��\n\u0012\t9��\u0015��y���������Q�w\u0007�m5��E��kJ!���\u0003�GQ���\u000f�:2�%\u0000`c�Sd���2d-��c��v�4��Էb���(�Hz�B�\r\u0014�Q�H�>^N)��\u0015��I�����BB���v\u0016d�n�#5��}��|O�\u0014�\u0015���HT��1+����\u001dzt����*nsQG�Gm,��\u00160�>R��Z>\u0019�WX���I�y\u0019lt\u0015&�cum3[���\u001co#\u0000��\u0000����\u0004\u0011��\u001aK\u0018�[ w������6���k���m�iv���m\b�\u000e=���;Ӟ��)l!M��x��v\r4��\u001b\u0010��ְ=E��z�ˊ3�%����gu\b_�*���m�ё��`)��xv8\u001a\u001b�V�̎��U\b��4L���s\u000e\u0006$���\u0003S�"C��}+�oS��~�f�"�H\b\u0001\u0003�䌁��"���N��\u0010y��\u0007���JmX#&�;\tm\u0006J�\u001d{�\u0005����U]"��Jew\u0001�oJ�MO�,�\u0012;\u0013P�iy!�Z,k�\u0006*����ʠ�ֳu_\u0018�Z\u0015[�w(xf\u001d\u0005X���/\u0010=��\u0003�\u0004Ӳ%ͭǷ����\u0003�����\u0010Ԑ.�",1�����9��\fo�\u0007��o�\u0010���\u0016�\u000f�ЏΦ�d��+\u001f\u000f�\u0001Ԃ��s�=+���I6�dgq��\\�<��k?^�:w�/m���fP?\u0013]/�]-n�Yl�B��啇\u001cWC~��5fϡ�\u0005cP\u0007@\u00052w \u000e�f8��\u0000\u001d\u0006\u0005Cr�p+���ܤ�&�\b-J�\u0006�rA5�4C�=ph�C\u0017j)�f��$=$mޙt~sL��n�,L�\'Z�<.\u0010�z�\'�&`}��:���\u0015�|8+{s����p�\u000fȃ�(��n\u0002j\u0015�p_\u0014t\u0003\u000e��Q�6�\u0005c}�(�\u0000\u0013����\u001a�\u000f�\u00125\\����@���"hֺ����CyP:��qR+矅��O�.!ݵQ�C�?��)t;�G�i�Ci�|��6�\u000fz����l�\u0001�����B-�\u0013��ڲ\u001baT#\u0004t��Уr\rN9o!kF\u0012E\u000b��\u001b\u0004�L�U��\u0007�Y΍l&\u0007;�\u0010��\u0000xs��I<\u000f ܬWޣ\u0011\\��5�8\u0015I���;�\u000e���\u0015�Ȱ�\u000f���I�\u001d3��/M����\fn\u0011:<�]��<�鵞F!؜�\u001d��ףu�\u00113��\u0000���S��Ј�H�B��\'~J�ޤԄ����<�\u0017���,~��M�G\fP�J1<�f��;��M�s�����*/wC���\u0000�+��\u0007��!�\u0003�Ίe�\u000e{\f�#� \u001a��牼>\u0018ǫh����\u001fx�\u0013\u0018\u001b�H\u00061��u�W)\u001a&�\u001cu\u0005�Z����x�\u001a�\ta�T0�\\��9�\u001d�rQ\u0002�\n�k �\u0017PT��G�5��ڶ�\u0018a�g�V��ymb\u0011@��㕉W\n>���vE�!�\u0003*��Ys\u0003����&�����\u0011NL͂9��m�;L\f��J�$@\u0000�1X~2�[�\u001f:�\u001b͹*��⽓@����yq�;\u000f�\u0003\u001c�5�<ګ�6k\u0015�Q�\u0019e<Sс50\u0000�V�G\u0003v1����QK\u0017���+�����ⳕ2�364!�QWDc4R�l�3\u0016W\fi��j\u0010�\u001di�\u000fZ��\u001cæn+o����ľv��\u00139=�Z��\'�hx9X먊�C�V�Rh�\r/ޣ����mCl�Ls�\n��\f�_>� �|C�X��\t+�?�2{�s_I\u0014�c���Q�-�\u0006+�-Z�Q���a\u0012edgV\u001d3�\u0015����-w=�K�JG\u0004����&A�;f�/\u0005�4�\u0010\u0002�;v<zf�%��\u0018\u0019��&\\\u0019j(��;�گC\n���;�,�\u0011���Z]B�+X�\u0000y"��9=)���ȧ��\u000b[Y�\u0015��\u001c\u001fz�\u001fO\u00063s5�72��է���NF�\u0005q!\u0003��5Ϭ�V�x�n�E\'��(}�r(��<�ju�\u0014�"�\u0002\u0019�@䞄�\u0012YO\u001d��\u000f#\u001b��Qi�_�a��2\\D~ヒ=�f�6�5A=��Q��E���LN�{�t�qGue\u001c��\u001f��z�4���>�\u000e������\u0001���\nkv\u0017�X�\u0000ȦK�.�t\t�|�1�b��\u0005��\u00155���������� �I��,$�u�����~\u0018�_V���\u000f\u0011� f��t\u0000\u001a�����W\u0001��=9�w��@��7���f\n�<\u00029$��~uб�f����N:{A\u0012�sS\u0003ҫ�rEO( g5��5�+���w8�e�\u0006��=\u000f4X\u0013\u001aO�E:U qEC\u000b��75j0\u0018U\u0000\bj�np\u0005k\u0014&H�)l\'���;�q�3�\u000fCO\'#"��~n�\u0013E�m;������&�e��\u0011=�ׇˊc�;�)=�^Sy*��mJќ�\u0000��m+�Yn��sI��%��\u000b\\���9\u0017|g� ����\u000bٮ�X��ݦb\u0010�r\u000e\u0000c�?�sI#���\'SI\u001e��)$��xw\u001a\f\u0011�\'��x�k�b`#��(��W\u0017�d�F\u001dNbVڪNrq����n\u0011!r\u0010�\u0007\u0018�u=N��6,�V\u0017�� \f�8�5�SSյ{�$�X-:oc�\u0000V�����\u0006�\u001c!�\u0019���CP�VP��;�\u0006\u0002�Dddc\u001dO�H��s�~��ng\u0017�vd��\u001f�\u000f\u001e��t�\u0013F��\u0017E�%�9\\\u0003��\u0015�w�K�6C6�wq\u0004#qD����HR\b��V�=K�zB[���V�\u0014!��M�9��@<�\u0000�Mj�cU\t�����lb��\u001b�PNr�<W\'�\u001d)�n�[}E\u001f)����Z���i"�\\�8��6H�De�و\u0007���\u0018�Vڎ�5����K 8rB\u0014%p\b����\'v.Y/���\b�Ccdʌ^D����FF?J��-�Y�Ԣ���c����[�V\u0017�O\r��u��^jד�g\u0011�dsۜ��֞�\fs�ba\u0016�%�bF\b �=\u0018��;\u001dt\u0015�\u0006F\u000bc5�_\u0016�d��\u000bX�\u000fp\u0004d����j�\r<�ד��\u0004w����\u00012kzT\u000e���2}1�\u0000ꡙ�p��\u001d68l��#Q��I�?�O#e:���_�\u0000�A�FqU\u0004�^+�$�\u000f\u0012ߵw&�m���eVC�j�v9\u0004sS,�/5����ۧć�t\u0012�FMQ���5\b���O�\u00127����ʆ��\u0006M\u0015\r���[�N�������e0Ml��\u0014TR)\'5d\u0001�Q\u0018�Ȭ�b�No1-ܦ3��=+�t���S/#lh����\u0005���>1x��U:6�"����Ҏ|�{\u000f���s�Q�ɣ�_M\u0003H�\u0010\tY��|\u0013���\u0003���N�����͟Bx[\\�\u0016�<_,Q �#\'{\u001f_ֺ���4sG��l\u001c����\u001d+�<\u0019�<H�W��\u0003\u0004$��\f�_a�՛-zmJ��-\u000e�\u0002���\u001f�\u001c\u0012}\u0017��^��v=X�ǧY�G�Ȗ�0Y\t\u0005���sϾk����ֶ�\u0001�@\u0003$�����\u001d��39o5-�\u0000Xc\u0019���V���\u0005�sv1\u001b\u000f�6B�Os��N��Gc�mв�E��\u0019椞��fe�\u0003݅a�z��,g\u0004.H5-���*b��\u001dMZlq�z2o��IrU\u0018�\u000b����]*�I�Asמ���M��ԒI&[\u0003\u001cq��hI�D-̬臩\u0006�;\u001a9ͭY&�u\u0005��T�\u0000�{gҸ�\u0006����m�X������U\u001d_��\u0019ZS\u0011�U��\t���\u0012�L�٬ţ9y\u001f889�?��F���\u000e�L��\u0013\\3��\b\u0019=\t�\u0000�W���R���v��K����\u001e��u>#׭�4��L\u0011[�@\u000f\\�H��\u0007�\u0002k���J�<\u0019\\�G?��y�Z�\u001c���\u000b�J��1f$��MJA�j��.sW&;b�tlx��U��v��%����-�M˱^��5\u0004 3`Ջ��$U\u000byv�F{�L��H��3�抒)��QTٛFV��R!��Ձ\u0014�~J�+\rD�\u001f�k+�~"�����Ҁ�7�\u0004�o��\u00049��3△.��)6\u001d�֮a�\u0003����\u0012J҅?k ��?R�]CT�����<�G<�&���C{��:d���O\u001c$�P2T�#?�\u0001^\u0017wn\u0003\u0015U\u0002>\u00189�T�+ꯃ�\u0006��;$��4*\u0015�Ҷ���$u�\u0012rl�m6�\b"��ev\u001b[f�\u0002�\u0015#�\u0000A�Z|�F��*\\M#[�<ܨ�$c�A�y����\u0000�eӮ&�l#a\u0004�\u0000���ۜ�ڼ�\u0000F�iek9\u0018�#\u0019;OOBG�5��\u001e�7mΣľ(�����j�I\u001a��w��{�q�^8��3�&\u0011�\u0007�I\u0018�$�*��\u0000\u0011���!�\t#��h��(@p1�:\n�-\u0017̂h��\u0016$�d\u0000\u0002z�\u0003"�݋���>\u0013��;_1�2Hr\u0001�C��\u0000���M�E�\u0005̲8;�\u000eGS^\u0001�ͭ@�M\u001e�\u001f7�\u0012\u000e\u0007\u0003ۚ봿\u0017_[سK\ti\u0014\u0005p\u0007�$~��h�d{\u001d��2[��!l�B�c�\u0000�^q��RD����\u001b�\u0000���c���s\u0014eX�(�q���W\u0015�-n��I\u0018\fI\'B\t�@##\u001e������ni"ƫ������7\u00149��\u0006@\u001d?*��n��I��\u0019�C��>��s��\\>���e�7\u000e?x��!I�\u0006;��\u001f�5�H\u0011HU��+�\u0007҄������&�7�u\u0018��F�=�m\u0005�!W�G����%���\u0015\u0018\b�@�\u0000W/��\u0000Hł�w\u0011�yNP\u0011�\u001e��ֺ�q�����畉��+v\u001dfؔ�˦ͿZ�\u000eD���+f2=��η+Ò��Z\u0011�ٓU���\u0013�W\u001b�\u0002�+\u0015s>��\n�߉�\u0015��\u0001���+�O\u0014��L�\u001c�`ɢ���\u0019��q3ld\u0017\u0000���\u0013��k��V����<�\u0012�Վ+�־ \u0015V�I������\u0003�\u000e��Nu\u001e������_��ty��uK���\tԳ��>���B��e\u0003m�$W<���>��~�\u001c�W�ά�wt��)*\u0019�\u0000��\u00035i2Н9����hG��:\u0015��c���0�e\u0017s9=J�Y�#\u0013\u0003�\u00011�y#�Q���~���\u0014���[WX��\u001at�k��\u0017?x\u000fn��J�#8\n�##ېX��Q�\u000e\u0007�O�\u0005�PD\t\u001e�*��ê\u000f��oR��\u001b1�r����㴱�l��c���>A�\u0004\u001es^\u0011�o\u0000���}��-��IpN3�\u001f\u001c�cү~�\u001f\u0010v\\E��M�A0?����7�C�\\q�o�}\rsekb��\fo\u0019\u0018*�#��־v�\'N\\���US�2>A{���\u0013i�l�F�\\�\u001d�q]^�\u0004&Ѽ����u��#\u000fL�}+�u���Y\u0012Ioo\u0014)&JƇ\u000b���o¹��\u000eZ��Fg�0��qa��\u000e\u000f<��ߙ2�����1��\u0003\u000f�K`����V��\u0000�\u001a�m���V���FY�\u001d^*ki���[)%X�0�n�����3Q���-\u000b�0���[ �?�q��\u0012��j�\u001f�3��m��F6��23��ǯ�c�\\����}��C�pB\u0001�\u0000�\fWA�B/��VhdRw$\u0003�g$��\u00195�id�� @f;�O,\u0012:t&�v#��!@�;oA��!K\u001e?�3C����\r�\u0000��b`����m�>i\u0002�#\u001d���v�\u001a�u����uzH�\u000ee!�\u001e�ߞ��|Z��H�]g�B���[t\u000b��p��&��9��\u0015gh���u�\rs��\u0017��d\t�Ⱦ����\u0000\u001a�$\u001a�_���zf��e�\u001c�Q��\u00120��e5�\b2y�����G����\\\u001c�؍�:F6TB"\u001f�c̘�\n�\u0014v�L�@ɦM\u0001\u000bU2�����5\u0016�Np+*C�\u0013W�FoZ��6zUGr]ȣ���\u0014U�T�QEi��l�������3<���r���QWf#�>R���6s��ڮ@$����"b\u0006X�\'Bp@�\u001d@���$��12!1n\n������}\f`��\u0006�FLh�ѫ��\bv�p3�A�Vdq.�m�.�l��\u0005\\\u0017�#��?Jb�3KS%�Ls\u0010�\fN�\u001c}q��\u0000�U\u001c,�\u0016�n\u0002�m�\b���`q�M7�֪勜\u0015K����\u0013\u001e��\u0000�}\b�����`r&�m�G�\u001dT�pz�>��\u000e��Փˍ�I\u001d��a�I=1�;\u001a"M��o������[���ݽ��N¸��%���\\LJ\u00067F۱�*�}\u0007\u0015���O�#�� ���G�Y�\'Pq�(����޾J_���8#�\u0018�\u0013�W����֏�<A�h:ŷ�,�e��\u001ftt�00P�\u0007����\u0013AV���Ѫ���:�}�\nI\u0019\f\u0001\r��8\'\u001dk+U����Ba��W�!��qֳ�\u0018��O�����]>Q��&���N1�Mu�F1����k�qqvg��q3x\u001fM�\u001d��\t\u0019-��׎?Z��\fQ"�Q�\b��e\u001f�\u001cס�b\u00032�\u0007A��M�Hp\u00004�\u0015ݏ=��$w�5��K3\f\u001d�\u001cc\u001d\u0001��K�x\u0017I�n��7;\u0001��O�\u000f�޻)���\\���\u0014ɑ�y�H�;\u001a\u0006�̴@\u0001@�ps�\u0018\u0019�1��p��������5̀\u000eȤ\u000f�y��+�.3\u001ce܍é�\u001f�$\u0017�2�o\u0019��#H\u0013\u001e�$�NJ���欎ld�i3�/u]G�~\'ԅ��A,w\f��e1�݂>�?�����\u0012�5\u0019c��\u0011-\'c��շ�W\u0017�Z�[��V ��!�.z�H��\u0005qq3\u0001��T�>��V�\n��pS~�gז�\u0000<`�\b#�9\u0000\u000f�5����\u0010�|�[_\u001b�m���S�\r��{c���C��*is�ڑIm#.wD��=Ǩ�*�\u0006�\u001e��*���p��R����zV��k\u0000\u001d>�\u0019��\u0003a��y�>�5�����!X���5\u0005�C\u0018�J_k��\r1�j�%�5L\u000e�T�P�U\u0019���K���+ƖY$!e@�\u0010H8 ����QD��{\u0012�$\u001eaP�\u0002v��\u0019玔Q_V�0nѹ\u0015�\u0013�@֨�\u0011��p\u0019\u000e}q�5X���c�9۝�\u001e2\u0001�qފ)=�OVK#��ծ\'RЍ��7|��\u001c{\u001fž�.�ĜF��e=w\u000f�os�c��h��c[_��q:���\u0004d\t9�\u001e��8��{�!.E�|�\u001b\f��\u001b�\u0003��\u0000��QR^�_��ǚ���K\u0016�\u0004�\u001d.f\u0011�Y�Op��\u0019�?����/�Xk�=����\t��\u0010:8=sE\u0015�f0�jH��I�ѪTt"�"\u0002�\f~4Q^[:��c\u0019T##9�\u0003�U�p\t\u0001y\u001d2h��QG7�k�&�V��\u001a��,b\u000b��\u0019s4�����p?�\u0014W��%�/�y���5�yo�8��V�d�#\u0016S�I\u0018\u001d�\u0000\u0003^fT%�P��8\u001b�8>�Q^�T��,;�\u0011m\u0017�m\u0000��ǖ@y�\u000f\\\u000f�\u001fΗ�A\u001bd��~l\u0000\u000f\u001d\u000f���mir�\u0016\u0019�N�E3G��4d2��]���?[ӭ���$�H�\u000b�Hr\u0007����T�R>�)7�w^\u001b�H�;\u001b;���7\f}\u0001���\u0007^1E\u0015��iF��\u0013h�F$�qȢ�+�����'
I figure that I need to return this in base64 to the user's browser, but when I try this, I get a broken image file.

The question I have - how do I encode/decode/format the above binary data to make my smiling face appear in the browser?  Just concatenating the base64 encoding of this binary string to the image tag (<img width="240" height="160" alt="jellyfishes" src="data:image/jpeg;base64,<base64string>>) doesn't do it.

Thanks a bunch in advance for the help on this one.

Scott
 
Hey fellow propellerheads,
 
I am building an integration with SFDC out of a node app, and I would like to get the URL to an attachment and provide it as a permalink (or a 30 day link if necessary) to an end user.  In essence, I'm looking to return the SRC="https://<myurl>/services/data/v37.0/sobject/Atachment/<AttachId>/Body" which my FE guy would throw into an <A> tag in both a page and an email.
 
I haven't seen anything out in the wild yet which would allow this - just a note in the docs stating that sending an email out of SFDC will give a permalink if the attachment is over 3MB.
 
Anyone out there have any examples of doing this?
 
Thanks in advance for  the help.
 
Scott
 
Federated SSO using jsForce
Hi everyone,

I'm currently trying to set up jsForce to connect to SFDC using a Federated Id.  The client has enabled SSO, and I am able to get an assertion from their identity server, but I am not sure how to use jsForce to get a token from Salesforce and then get the session id.

I have tried using Postman to set up the POST call with the assertion, like so:

POST /services/oauth2/token?so=00Dm00000008fCJ HTTP/1.1
Host: <mysandbox>.cs20.my.salesforce.com
Content-Type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW
Cache-Control: no-cache
Postman-Token: d8e0ad17-37ae-35a1-4207-d95b562d954d

------WebKitFormBoundary7MA4YWxkTrZu0gW
Content-Disposition: form-data; name="assertion"

PHNhbWxwOlJlc3BvbnNlIHhtbG5zOnNhbWxwPSJ1cm46b2FzaXM6bmFtZXM6dGM6%0D%0AU0FNTDoyLjA6cHJvdG9jb2wiIHhtbG5zOmRzaWc9Imh0dHA6Ly93d3cudzMub3Jn%0D%0ALzIwMDAvMDkveG1sZHNp<clipped for brevity>3D%0D%0A
------WebKitFormBoundary7MA4YWxkTrZu0gW
Content-Disposition: form-data; name="grant_type"

urn%3Aietf%3Aparams%3Aoauth%3Agrant-type%3Asaml2-bearer
------WebKitFormBoundary7MA4YWxkTrZu0gW
Content-Disposition: form-data; name="RelayState"

%2F
------WebKitFormBoundary7MA4YWxkTrZu0gW--


I'm using the saml2-bearer grant type as specified within the docs (https://help.salesforce.com/apex/HTViewHelpDoc?id=remoteaccess_oauth_SAML_bearer_flow.htm&language=en_US) but I still get the following response:  

{
  "error": "unsupported_grant_type",
  "error_description": "grant type not supported"
}

Does anyone know where I need to go to suss out the root cause of this?

Thanks in advance for your help.
I have followed the instructions for creating a sfdx project locally and converted all of my metadata to the sfdx format. Now I want to push my local meta data to my scratch org but I receive a huge list of errors. Most of them are that the objects are different and items don't exist, which I know because it's the first time I want to push my local version to the scratch org so my scratch org matches my production/sandbox metadata.Has anyone had this problem and have any advice to how to deploy my local set of metadata to a scratch org? I tried to use the --forceoverwrite parameter on sfdx push, but I still receive a LOT of errors such as invalid type, field does not exist, etc. I would think this command would overwrite what is on the scratch org with what I am pushing to it. Thanks for any advice
I'm trying to parse JSON to extract a Zip Code from a JSON response. Instead of returning "10019-6018", the parser is returning "null10019-6019". Why is it inserting "null" in front of the value?

Here's the body of JSON response:
 
{"Addresses":[{"Address1":"787 7th Ave Fl 8th","Address2":"","City":"New 
York","State":"NY","Zip":"10019-018","IsResidential":"","DPV":"3"}],"IsCASS":true}

Here's a snippet of code showing what I'm doing with the parser:
 
HttpResponse response;
        response = h.send(req);
        System.debug(response.getBody());
        JSONParser parser = JSON.createParser(response.getBody());
        String resPostalCode;
        while(parser.nextToken() != null) {
            if((parser.getCurrentToken() == JSONToken.FIELD_NAME) && 
               (parser.getText() == 'Zip')) {
                   parser.nextToken();
                   resPostalCode += parser.getText();
            }
        }
        system.debug(resPostalCode);

 
Hi folks,

I am trying to access and send the body of an attachment to a node.js server.  In essence what I want to do is get the data, pop it into a data URL (i.e. <img width="240" height="160" alt="scromie" src="data:image/jpeg;base64,/f39/QAQSkZJRgABAgAAAQABAAD9/QBDAAUDBAQEAwUEBAQFBQUGBwwIBwcHBw8KCwkMEQ8SEhEPERATFhwXExQaFRARGCEYGhwdHx8fExciJCIeJBweHx79/QBDAQUFBQcGBw4ICA4eFBEUHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh79....(data continues))">

I have worked out receiving the attachment body through the jsForce library's request module, like so:
 
var conn = result;
      var attBlob = conn.sobject('Attachment').record(req.query.attachId).blob('Body');
      var server = conn.instanceUrl;
      var resource = 'services/data/v37.0/sobjects/Attachment/' + req.query.attachId + '/Body';
      var resourceURL = server + resource;
      var options = { method: 'GET',
                      url: resourceURL,
                      headers:
                      {
                        authorization: 'Bearer \'' + conn.accessToken + '\''
                      }
                    };
      var attData = conn.request(options);
At the end of this, I get what I believe to be the binary data for the attachment: 
 
'����\u0000\u0010JFIF\u0000\u0001\u0002\u0000\u0000\u0001\u0000\u0001\u0000\u0000��\u0000C\u0000\u0005\u0003\u0004\u0004\u0004\u0003\u0005\u0004\u0004\u0004\u0005\u0005\u0005\u0006\u0007\f\b\u0007\u0007\u0007\u0007\u000f\n\u000b\t\f\u0011\u000f\u0012\u0012\u0011\u000f\u0011\u0010\u0013\u0016\u001c\u0017\u0013\u0014\u001a\u0015\u0010\u0011\u0018!\u0018\u001a\u001c\u001d\u001f\u001f\u001f\u0013\u0017"$"\u001e$\u001c\u001e\u001f\u001e��\u0000C\u0001\u0005\u0005\u0005\u0007\u0006\u0007\u000e\b\b\u000e\u001e\u0014\u0011\u0014\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e\u001e��\u0000\u0011\b\u0000�\u0000�\u0003\u0001"\u0000\u0002\u0011\u0001\u0003\u0011\u0001��\u0000\u001f\u0000\u0000\u0001\u0005\u0001\u0001\u0001\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b��\u0000�\u0010\u0000\u0002\u0001\u0003\u0003\u0002\u0004\u0003\u0005\u0005\u0004\u0004\u0000\u0000\u0001}\u0001\u0002\u0003\u0000\u0004\u0011\u0005\u0012!1A\u0006\u0013Qa\u0007"q\u00142���\b#B��\u0015R��$3br�\t\n\u0016\u0017\u0018\u0019\u001a%&\'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz���������������������������������������������������������������������������\u0000\u001f\u0001\u0000\u0003\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b��\u0000�\u0011\u0000\u0002\u0001\u0002\u0004\u0004\u0003\u0004\u0007\u0005\u0004\u0004\u0000\u0001\u0002w\u0000\u0001\u0002\u0003\u0011\u0004\u0005!1\u0006\u0012AQ\u0007aq\u0013"2�\b\u0014B����\t#3R�\u0015br�\n\u0016$4�%�\u0017\u0018\u0019\u001a&\'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz��������������������������������������������������������������������������\u0000\f\u0003\u0001\u0000\u0002\u0011\u0003\u0011\u0000?\u0000�\'�Y�\\�j\u0002��v�\u0001��\u0011��\u0004`�r�i[��)\u0017֭\bz�V�SA�N_��C�\u0011\u0014�\\�c5\rɽ�O��%�X�VB�?\f`�u����}���X�ټ�ɕa#(\u0011�l� ��\u0011���5�=\u0014ŏ��=�&��~\u001aӥh�5�8�V\nPɒ\u000f��|����Ś����݄n��v.=0\u0000��>�g�1,[�ߟ���t,:KS7&�h��.hp�=�����+m�T�V�\u0019�Q��\u0000\u001at�-�����pf\u000b$[��x7s��^==���I�\u0014\u0004\u001d���]Z�a�q��CЌv�#J\u0002�ϡ����\u0015��G=��o&�`(p\u0006z�"�]\u000b��\u0007�\u0016C�jv�f<o\bܮzdW��\u0013gv�`�U-��ͺ�PL�\u0019�0\fF�3��:%���Q�G�SG���)�0��V��O\u0012h�o\u0015��4qŝ��ʶy�ֽO�\u0019��J�(��\u00013\u001c�F[,:����\u001eQ�Ӝ�\tF[\u0014�\u001f\u00195疿\u0016�\u0019u��D��\u0019\b\t4q��\'\u0018e ~��F�X� Yb9F\u0000���r�CԮ\u0014\u0007��+\u0001QF��7F��Pi&b\u0005\'\u0011&9�\u0007#4л�P)�U�z���1ȻNj�l�A �F)�\u0003��\u0015\u0013Z�\u0006D�\u000fE:s���e\u001c�x��8\u0015\\\u0003�z1\u0015��M�h�*)\u001c\u0015\u0015\u001c2\u000e\u0005K+es��\u0011�u\u0006�k�!�|?`�z���\u0014}�c�\u0017�s?\u0010<qg��q\u001cJ\'�pv�\u001f\u0000{�+�u�cR�\u0016����\u000b3}���j�Rmݎ�������{\u0013��0�\n��M.\u000b��\u0000tv��^t�NŦ�&V?19��j兤��\u001eEWR3�p?\u001a��G�,\u001d�!\u0017�G���Q��0mjT"�(�\f\t���\u0014��X�\u001321���\u001b {�}��=�n�X�1�F\u0007�Z�T76Jb�H\\�Q� ��G:e�9ng���u�\ncq����e�[=��UĐ7̎?�n�XI\u0014�9l�XG\u001b�9Q�\u001e�JM>T���Y!\u0007��\u001f��M2\\\u001b1�[�;��6�\u001f&O�Zٺ��\u0018��7G���+>�\u000f.]��#=*��.\r\u0015�H�\u0010�E^�p.\u0010"g\u0007��\u001f�U州&\u0012�*\t�&�j�Y�=�s��-���\u0012�dvd���\u00108�I�{��V9�Ӯ[φS堖B\u0000�\u001d@�\u0015�Qe�\u000b\b��+�q�}���K4aNT��}�f�@����K��ӭ�e��1��8�̹\u001d+�~\u000ex�T�":v�:JbA��̌��\'��K(2+4�f�v(\u0004 �S����\r\u0018�"�1d�۸���\u00188�8\u0001\rT�yk��W\u00053�͢Ӱɓ<�NG\f9�\u0015���r�\u001c�O+\u0002��6♀\u00051\u0010Ƅv��\u0014�0��L�Sr@¨�O�l�3���\u0000�n��VЂ��M��Z$4��\u001b�.��ui�/��g9\u0003�\u001e߅K�Y�w�(\u001b\u0014e��Ui�Q�j��v�\u001d\u0005_�Q$!\u0015�\u0018P_�N\u0000����hZZ���K1�@8\u0018��]7�|(u���u�\u0006�=ϵd��\u001c�C\u0018\u0000g����?ҽ��6��Y�\u00111\r�����:��i\u0011�\u001f\u000e��\u0002����\u0019]�-]����O�=��4Ls�\u00075���\u0011\u0007�\u0001�8�[�z\f\u0002\u000e+\u0017#��V<���.�q\u0000H�L\f\u0002�\u0003��\\���k�\u000b�n4���\f\u000eT�\u0006ϵ}\b���<\u001a�h#�\u001a��d⏓O��ئ�>ŏ5\u000f�nAdz)��zVe��-JL!�g�\u000eF����^����2��c+�8�C\fH0#E\u001e¯��n�g�����V�w�\u001at�\u0010��?�T�����Zm:�����1_��ZF�t{j��8\u0018��C�zSDPZD\u0007�\\�s%QL�,葂L�iC��x��֬��\u0011�Y\u0004���F\r};�O��|��\u0004k\u0011n�W\u0015�׉���� ��U���\u0007$0�I6�:q��s��{V��������e\u001c}\u0018w���\u0013�8�E�E}\u0018U�|�"��q�\u001e����,\u0017�˵A\f>^�H����|\u0017Ԯ,���Wa\u0014��\u0016p7\noDqԂl����RB2y\u0014Z(� �p\b�59@��K��{X�O�TL�J�^I\u0015\u0011\u0019\u00157*�BM�\u0014R:w��\t(\u0013��7L��q�T\\�I\u0014@\t�y\u0015��\u0017�\t���\u0000d��b@T\u0001�׵<x�\u0015��o\f~\'i\u0018<�<`�-T7*;�$��"aUT�3�9�Kp�\u0003kn2�����VfUf@_{�\u0000��7\n��F��7\u0018\u001dk��[S��{j&�@q�Xs��_P�V�[�p����\u0007�\u0015�?\u0002�k�����\u0016�#?!a�k��5v�V�\u001e��������W6m�8\u0001zV���\u000e\t�Q��@�|��S\b�C������u�\u001d��\u0006�\u0017��\u00122k#�/��ж�#s�zS��\u00136��v\u001c5#J\u0017�T"ʎ8�j;��\u0018\u0007\u0014\\J���wI�1��D���\u001c��s�$�8\'��mn���P�{;\t�@���Ҿe����\u000e�o|���U���k�\t�4L\u00063��?�+Ow�ٺU;�l��j����>&\u0017�Ϛ��b�L\u0003���\u000f����1�\u0000#\u001d��Y�n\b�\b���\u0015�:��\n\u0012\t9��\u0015��y���������Q�w\u0007�m5��E��kJ!���\u0003�GQ���\u000f�:2�%\u0000`c�Sd���2d-��c��v�4��Էb���(�Hz�B�\r\u0014�Q�H�>^N)��\u0015��I�����BB���v\u0016d�n�#5��}��|O�\u0014�\u0015���HT��1+����\u001dzt����*nsQG�Gm,��\u00160�>R��Z>\u0019�WX���I�y\u0019lt\u0015&�cum3[���\u001co#\u0000��\u0000����\u0004\u0011��\u001aK\u0018�[ w������6���k���m�iv���m\b�\u000e=���;Ӟ��)l!M��x��v\r4��\u001b\u0010��ְ=E��z�ˊ3�%����gu\b_�*���m�ё��`)��xv8\u001a\u001b�V�̎��U\b��4L���s\u000e\u0006$���\u0003S�"C��}+�oS��~�f�"�H\b\u0001\u0003�䌁��"���N��\u0010y��\u0007���JmX#&�;\tm\u0006J�\u001d{�\u0005����U]"��Jew\u0001�oJ�MO�,�\u0012;\u0013P�iy!�Z,k�\u0006*����ʠ�ֳu_\u0018�Z\u0015[�w(xf\u001d\u0005X���/\u0010=��\u0003�\u0004Ӳ%ͭǷ����\u0003�����\u0010Ԑ.�",1�����9��\fo�\u0007��o�\u0010���\u0016�\u000f�ЏΦ�d��+\u001f\u000f�\u0001Ԃ��s�=+���I6�dgq��\\�<��k?^�:w�/m���fP?\u0013]/�]-n�Yl�B��啇\u001cWC~��5fϡ�\u0005cP\u0007@\u00052w \u000e�f8��\u0000\u001d\u0006\u0005Cr�p+���ܤ�&�\b-J�\u0006�rA5�4C�=ph�C\u0017j)�f��$=$mޙt~sL��n�,L�\'Z�<.\u0010�z�\'�&`}��:���\u0015�|8+{s����p�\u000fȃ�(��n\u0002j\u0015�p_\u0014t\u0003\u000e��Q�6�\u0005c}�(�\u0000\u0013����\u001a�\u000f�\u00125\\����@���"hֺ����CyP:��qR+矅��O�.!ݵQ�C�?��)t;�G�i�Ci�|��6�\u000fz����l�\u0001�����B-�\u0013��ڲ\u001baT#\u0004t��Уr\rN9o!kF\u0012E\u000b��\u001b\u0004�L�U��\u0007�Y΍l&\u0007;�\u0010��\u0000xs��I<\u000f ܬWޣ\u0011\\��5�8\u0015I���;�\u000e���\u0015�Ȱ�\u000f���I�\u001d3��/M����\fn\u0011:<�]��<�鵞F!؜�\u001d��ףu�\u00113��\u0000���S��Ј�H�B��\'~J�ޤԄ����<�\u0017���,~��M�G\fP�J1<�f��;��M�s�����*/wC���\u0000�+��\u0007��!�\u0003�Ίe�\u000e{\f�#� \u001a��牼>\u0018ǫh����\u001fx�\u0013\u0018\u001b�H\u00061��u�W)\u001a&�\u001cu\u0005�Z����x�\u001a�\ta�T0�\\��9�\u001d�rQ\u0002�\n�k �\u0017PT��G�5��ڶ�\u0018a�g�V��ymb\u0011@��㕉W\n>���vE�!�\u0003*��Ys\u0003����&�����\u0011NL͂9��m�;L\f��J�$@\u0000�1X~2�[�\u001f:�\u001b͹*��⽓@����yq�;\u000f�\u0003\u001c�5�<ګ�6k\u0015�Q�\u0019e<Sс50\u0000�V�G\u0003v1����QK\u0017���+�����ⳕ2�364!�QWDc4R�l�3\u0016W\fi��j\u0010�\u001di�\u000fZ��\u001cæn+o����ľv��\u00139=�Z��\'�hx9X먊�C�V�Rh�\r/ޣ����mCl�Ls�\n��\f�_>� �|C�X��\t+�?�2{�s_I\u0014�c���Q�-�\u0006+�-Z�Q���a\u0012edgV\u001d3�\u0015����-w=�K�JG\u0004����&A�;f�/\u0005�4�\u0010\u0002�;v<zf�%��\u0018\u0019��&\\\u0019j(��;�گC\n���;�,�\u0011���Z]B�+X�\u0000y"��9=)���ȧ��\u000b[Y�\u0015��\u001c\u001fz�\u001fO\u00063s5�72��է���NF�\u0005q!\u0003��5Ϭ�V�x�n�E\'��(}�r(��<�ju�\u0014�"�\u0002\u0019�@䞄�\u0012YO\u001d��\u000f#\u001b��Qi�_�a��2\\D~ヒ=�f�6�5A=��Q��E���LN�{�t�qGue\u001c��\u001f��z�4���>�\u000e������\u0001���\nkv\u0017�X�\u0000ȦK�.�t\t�|�1�b��\u0005��\u00155���������� �I��,$�u�����~\u0018�_V���\u000f\u0011� f��t\u0000\u001a�����W\u0001��=9�w��@��7���f\n�<\u00029$��~uб�f����N:{A\u0012�sS\u0003ҫ�rEO( g5��5�+���w8�e�\u0006��=\u000f4X\u0013\u001aO�E:U qEC\u000b��75j0\u0018U\u0000\bj�np\u0005k\u0014&H�)l\'���;�q�3�\u000fCO\'#"��~n�\u0013E�m;������&�e��\u0011=�ׇˊc�;�)=�^Sy*��mJќ�\u0000��m+�Yn��sI��%��\u000b\\���9\u0017|g� ����\u000bٮ�X��ݦb\u0010�r\u000e\u0000c�?�sI#���\'SI\u001e��)$��xw\u001a\f\u0011�\'��x�k�b`#��(��W\u0017�d�F\u001dNbVڪNrq����n\u0011!r\u0010�\u0007\u0018�u=N��6,�V\u0017�� \f�8�5�SSյ{�$�X-:oc�\u0000V�����\u0006�\u001c!�\u0019���CP�VP��;�\u0006\u0002�Dddc\u001dO�H��s�~��ng\u0017�vd��\u001f�\u000f\u001e��t�\u0013F��\u0017E�%�9\\\u0003��\u0015�w�K�6C6�wq\u0004#qD����HR\b��V�=K�zB[���V�\u0014!��M�9��@<�\u0000�Mj�cU\t�����lb��\u001b�PNr�<W\'�\u001d)�n�[}E\u001f)����Z���i"�\\�8��6H�De�و\u0007���\u0018�Vڎ�5����K 8rB\u0014%p\b����\'v.Y/���\b�Ccdʌ^D����FF?J��-�Y�Ԣ���c����[�V\u0017�O\r��u��^jד�g\u0011�dsۜ��֞�\fs�ba\u0016�%�bF\b �=\u0018��;\u001dt\u0015�\u0006F\u000bc5�_\u0016�d��\u000bX�\u000fp\u0004d����j�\r<�ד��\u0004w����\u00012kzT\u000e���2}1�\u0000ꡙ�p��\u001d68l��#Q��I�?�O#e:���_�\u0000�A�FqU\u0004�^+�$�\u000f\u0012ߵw&�m���eVC�j�v9\u0004sS,�/5����ۧć�t\u0012�FMQ���5\b���O�\u00127����ʆ��\u0006M\u0015\r���[�N�������e0Ml��\u0014TR)\'5d\u0001�Q\u0018�Ȭ�b�No1-ܦ3��=+�t���S/#lh����\u0005���>1x��U:6�"����Ҏ|�{\u000f���s�Q�ɣ�_M\u0003H�\u0010\tY��|\u0013���\u0003���N�����͟Bx[\\�\u0016�<_,Q �#\'{\u001f_ֺ���4sG��l\u001c����\u001d+�<\u0019�<H�W��\u0003\u0004$��\f�_a�՛-zmJ��-\u000e�\u0002���\u001f�\u001c\u0012}\u0017��^��v=X�ǧY�G�Ȗ�0Y\t\u0005���sϾk����ֶ�\u0001�@\u0003$�����\u001d��39o5-�\u0000Xc\u0019���V���\u0005�sv1\u001b\u000f�6B�Os��N��Gc�mв�E��\u0019椞��fe�\u0003݅a�z��,g\u0004.H5-���*b��\u001dMZlq�z2o��IrU\u0018�\u000b����]*�I�Asמ���M��ԒI&[\u0003\u001cq��hI�D-̬臩\u0006�;\u001a9ͭY&�u\u0005��T�\u0000�{gҸ�\u0006����m�X������U\u001d_��\u0019ZS\u0011�U��\t���\u0012�L�٬ţ9y\u001f889�?��F���\u000e�L��\u0013\\3��\b\u0019=\t�\u0000�W���R���v��K����\u001e��u>#׭�4��L\u0011[�@\u000f\\�H��\u0007�\u0002k���J�<\u0019\\�G?��y�Z�\u001c���\u000b�J��1f$��MJA�j��.sW&;b�tlx��U��v��%����-�M˱^��5\u0004 3`Ջ��$U\u000byv�F{�L��H��3�抒)��QTٛFV��R!��Ձ\u0014�~J�+\rD�\u001f�k+�~"�����Ҁ�7�\u0004�o��\u00049��3△.��)6\u001d�֮a�\u0003����\u0012J҅?k ��?R�]CT�����<�G<�&���C{��:d���O\u001c$�P2T�#?�\u0001^\u0017wn\u0003\u0015U\u0002>\u00189�T�+ꯃ�\u0006��;$��4*\u0015�Ҷ���$u�\u0012rl�m6�\b"��ev\u001b[f�\u0002�\u0015#�\u0000A�Z|�F��*\\M#[�<ܨ�$c�A�y����\u0000�eӮ&�l#a\u0004�\u0000���ۜ�ڼ�\u0000F�iek9\u0018�#\u0019;OOBG�5��\u001e�7mΣľ(�����j�I\u001a��w��{�q�^8��3�&\u0011�\u0007�I\u0018�$�*��\u0000\u0011���!�\t#��h��(@p1�:\n�-\u0017̂h��\u0016$�d\u0000\u0002z�\u0003"�݋���>\u0013��;_1�2Hr\u0001�C��\u0000���M�E�\u0005̲8;�\u000eGS^\u0001�ͭ@�M\u001e�\u001f7�\u0012\u000e\u0007\u0003ۚ봿\u0017_[سK\ti\u0014\u0005p\u0007�$~��h�d{\u001d��2[��!l�B�c�\u0000�^q��RD����\u001b�\u0000���c���s\u0014eX�(�q���W\u0015�-n��I\u0018\fI\'B\t�@##\u001e������ni"ƫ������7\u00149��\u0006@\u001d?*��n��I��\u0019�C��>��s��\\>���e�7\u000e?x��!I�\u0006;��\u001f�5�H\u0011HU��+�\u0007҄������&�7�u\u0018��F�=�m\u0005�!W�G����%���\u0015\u0018\b�@�\u0000W/��\u0000Hł�w\u0011�yNP\u0011�\u001e��ֺ�q�����畉��+v\u001dfؔ�˦ͿZ�\u000eD���+f2=��η+Ò��Z\u0011�ٓU���\u0013�W\u001b�\u0002�+\u0015s>��\n�߉�\u0015��\u0001���+�O\u0014��L�\u001c�`ɢ���\u0019��q3ld\u0017\u0000���\u0013��k��V����<�\u0012�Վ+�־ \u0015V�I������\u0003�\u000e��Nu\u001e������_��ty��uK���\tԳ��>���B��e\u0003m�$W<���>��~�\u001c�W�ά�wt��)*\u0019�\u0000��\u00035i2Н9����hG��:\u0015��c���0�e\u0017s9=J�Y�#\u0013\u0003�\u00011�y#�Q���~���\u0014���[WX��\u001at�k��\u0017?x\u000fn��J�#8\n�##ېX��Q�\u000e\u0007�O�\u0005�PD\t\u001e�*��ê\u000f��oR��\u001b1�r����㴱�l��c���>A�\u0004\u001es^\u0011�o\u0000���}��-��IpN3�\u001f\u001c�cү~�\u001f\u0010v\\E��M�A0?����7�C�\\q�o�}\rsekb��\fo\u0019\u0018*�#��־v�\'N\\���US�2>A{���\u0013i�l�F�\\�\u001d�q]^�\u0004&Ѽ����u��#\u000fL�}+�u���Y\u0012Ioo\u0014)&JƇ\u000b���o¹��\u000eZ��Fg�0��qa��\u000e\u000f<��ߙ2�����1��\u0003\u000f�K`����V��\u0000�\u001a�m���V���FY�\u001d^*ki���[)%X�0�n�����3Q���-\u000b�0���[ �?�q��\u0012��j�\u001f�3��m��F6��23��ǯ�c�\\����}��C�pB\u0001�\u0000�\fWA�B/��VhdRw$\u0003�g$��\u00195�id�� @f;�O,\u0012:t&�v#��!@�;oA��!K\u001e?�3C����\r�\u0000��b`����m�>i\u0002�#\u001d���v�\u001a�u����uzH�\u000ee!�\u001e�ߞ��|Z��H�]g�B���[t\u000b��p��&��9��\u0015gh���u�\rs��\u0017��d\t�Ⱦ����\u0000\u001a�$\u001a�_���zf��e�\u001c�Q��\u00120��e5�\b2y�����G����\\\u001c�؍�:F6TB"\u001f�c̘�\n�\u0014v�L�@ɦM\u0001\u000bU2�����5\u0016�Np+*C�\u0013W�FoZ��6zUGr]ȣ���\u0014U�T�QEi��l�������3<���r���QWf#�>R���6s��ڮ@$����"b\u0006X�\'Bp@�\u001d@���$��12!1n\n������}\f`��\u0006�FLh�ѫ��\bv�p3�A�Vdq.�m�.�l��\u0005\\\u0017�#��?Jb�3KS%�Ls\u0010�\fN�\u001c}q��\u0000�U\u001c,�\u0016�n\u0002�m�\b���`q�M7�֪勜\u0015K����\u0013\u001e��\u0000�}\b�����`r&�m�G�\u001dT�pz�>��\u000e��Փˍ�I\u001d��a�I=1�;\u001a"M��o������[���ݽ��N¸��%���\\LJ\u00067F۱�*�}\u0007\u0015���O�#�� ���G�Y�\'Pq�(����޾J_���8#�\u0018�\u0013�W����֏�<A�h:ŷ�,�e��\u001ftt�00P�\u0007����\u0013AV���Ѫ���:�}�\nI\u0019\f\u0001\r��8\'\u001dk+U����Ba��W�!��qֳ�\u0018��O�����]>Q��&���N1�Mu�F1����k�qqvg��q3x\u001fM�\u001d��\t\u0019-��׎?Z��\fQ"�Q�\b��e\u001f�\u001cס�b\u00032�\u0007A��M�Hp\u00004�\u0015ݏ=��$w�5��K3\f\u001d�\u001cc\u001d\u0001��K�x\u0017I�n��7;\u0001��O�\u000f�޻)���\\���\u0014ɑ�y�H�;\u001a\u0006�̴@\u0001@�ps�\u0018\u0019�1��p��������5̀\u000eȤ\u000f�y��+�.3\u001ce܍é�\u001f�$\u0017�2�o\u0019��#H\u0013\u001e�$�NJ���欎ld�i3�/u]G�~\'ԅ��A,w\f��e1�݂>�?�����\u0012�5\u0019c��\u0011-\'c��շ�W\u0017�Z�[��V ��!�.z�H��\u0005qq3\u0001��T�>��V�\n��pS~�gז�\u0000<`�\b#�9\u0000\u000f�5����\u0010�|�[_\u001b�m���S�\r��{c���C��*is�ڑIm#.wD��=Ǩ�*�\u0006�\u001e��*���p��R����zV��k\u0000\u001d>�\u0019��\u0003a��y�>�5�����!X���5\u0005�C\u0018�J_k��\r1�j�%�5L\u000e�T�P�U\u0019���K���+ƖY$!e@�\u0010H8 ����QD��{\u0012�$\u001eaP�\u0002v��\u0019玔Q_V�0nѹ\u0015�\u0013�@֨�\u0011��p\u0019\u000e}q�5X���c�9۝�\u001e2\u0001�qފ)=�OVK#��ծ\'RЍ��7|��\u001c{\u001fž�.�ĜF��e=w\u000f�os�c��h��c[_��q:���\u0004d\t9�\u001e��8��{�!.E�|�\u001b\f��\u001b�\u0003��\u0000��QR^�_��ǚ���K\u0016�\u0004�\u001d.f\u0011�Y�Op��\u0019�?����/�Xk�=����\t��\u0010:8=sE\u0015�f0�jH��I�ѪTt"�"\u0002�\f~4Q^[:��c\u0019T##9�\u0003�U�p\t\u0001y\u001d2h��QG7�k�&�V��\u001a��,b\u000b��\u0019s4�����p?�\u0014W��%�/�y���5�yo�8��V�d�#\u0016S�I\u0018\u001d�\u0000\u0003^fT%�P��8\u001b�8>�Q^�T��,;�\u0011m\u0017�m\u0000��ǖ@y�\u000f\\\u000f�\u001fΗ�A\u001bd��~l\u0000\u000f\u001d\u000f���mir�\u0016\u0019�N�E3G��4d2��]���?[ӭ���$�H�\u000b�Hr\u0007����T�R>�)7�w^\u001b�H�;\u001b;���7\f}\u0001���\u0007^1E\u0015��iF��\u0013h�F$�qȢ�+�����'
I figure that I need to return this in base64 to the user's browser, but when I try this, I get a broken image file.

The question I have - how do I encode/decode/format the above binary data to make my smiling face appear in the browser?  Just concatenating the base64 encoding of this binary string to the image tag (<img width="240" height="160" alt="jellyfishes" src="data:image/jpeg;base64,<base64string>>) doesn't do it.

Thanks a bunch in advance for the help on this one.

Scott
 
This is a warning to every Visualforce developer here. Salesforce will clober your javascript at any time with no warning. I experienced a 100% customer outage due to Salesforce updating their Javascript in the middle of the night a couple weeks ago. This was their customer support response from tier 3:


"Customers should be namespacing (well, pseudo-namespacing) their JavaScript code to avoid collisions like this. That's just standard web development method."

"Salesforce libraries are growing faster and we cannot possibly document every global variable/function that we're adding to the JavaScript that is served with Salesforce."
 

Hi Apex experts,

Looking at Attachment declaration I noticed that Body field is of type Base64.

The Body is an encoded data of a file.

Now, How can I decode the Body data? So I'll get the original contents of the file (it may be in bytes because I can use convert).

 

Another question.

Lets' say that I have the files data. How can I pass its data to me WebService written in C#? (what kind of type shall I use?)

 

Thank you so much!

 

 

This is a warning to every Visualforce developer here. Salesforce will clober your javascript at any time with no warning. I experienced a 100% customer outage due to Salesforce updating their Javascript in the middle of the night a couple weeks ago. This was their customer support response from tier 3:


"Customers should be namespacing (well, pseudo-namespacing) their JavaScript code to avoid collisions like this. That's just standard web development method."

"Salesforce libraries are growing faster and we cannot possibly document every global variable/function that we're adding to the JavaScript that is served with Salesforce."